aboutsummaryrefslogtreecommitdiffstats
path: root/modules/htmlutil/html_test.go
blob: 5ff05d75b36cc130a5e9d3371d91dccdbeed2e96 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// Copyright 2024 The Gitea Authors. All rights reserved.
// SPDX-License-Identifier: MIT

package htmlutil

import (
	"html/template"
	"testing"

	"github.com/stretchr/testify/assert"
)

func TestHTMLFormat(t *testing.T) {
	assert.Equal(t, template.HTML("<a>&lt; < 1</a>"), HTMLFormat("<a>%s %s %d</a>", "<", template.HTML("<"), 1))
}