// Copyright 2024 The Gitea Authors. All rights reserved. // SPDX-License-Identifier: MIT package markup import ( "testing" "github.com/stretchr/testify/assert" ) func TestDescriptionSanitizer(t *testing.T) { testCases := []string{ `
 `, ``,
		`THUMBS UP`, `THUMBS UP`,
		`Hello World`, `Hello World`,
		`
`, ``,
		`THUMBS UP`, `THUMBS UP`,
		`Hello World`, `Hello World`,
		`wg(8) tool`, `Provides alternative wg(8) tool`,
	}
	for i := 0; i < len(testCases); i += 2 {
		assert.Equal(t, testCases[i+1], SanitizeDescription(testCases[i]))
	}
}