mirror of
https://github.com/go-gitea/gitea.git
synced 2024-05-11 05:55:29 +00:00
Fix commit sha1 URL rendering in markdown (#1677)
* Fix commit sha1 URL rendering in markdown * Add unit test for commit sha1 markdown rendering when sha1 has space before it * Change to better variable name
This commit is contained in:
@ -296,6 +296,7 @@ func TestRender_Commits(t *testing.T) {
|
||||
test(sha, `<p><a href="`+commit+`" rel="nofollow">b6dd6210ea</a></p>`)
|
||||
test(commit, `<p><a href="`+commit+`" rel="nofollow">b6dd6210ea</a></p>`)
|
||||
test(tree, `<p><a href="`+src+`" rel="nofollow">b6dd6210ea/src</a></p>`)
|
||||
test("commit "+sha, `<p>commit <a href="`+commit+`" rel="nofollow">b6dd6210ea</a></p>`)
|
||||
}
|
||||
|
||||
func TestRender_Images(t *testing.T) {
|
||||
|
Reference in New Issue
Block a user