mirror of
https://github.com/yuin/goldmark
synced 2025-03-04 23:04:52 +00:00
move test to its correct place...
This commit is contained in:
parent
2a86c1ea31
commit
3a828e641d
2 changed files with 18 additions and 23 deletions
|
|
@ -76,3 +76,21 @@ place where everything breaks")
|
||||||
place where everything breaks">This link won't be rendered
|
place where everything breaks">This link won't be rendered
|
||||||
correctly</a></p>
|
correctly</a></p>
|
||||||
//= = = = = = = = = = = = = = = = = = = = = = = =//
|
//= = = = = = = = = = = = = = = = = = = = = = = =//
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
7
|
||||||
|
//- - - - - - - - -//
|
||||||
|
[](./target.md)
|
||||||
|
//- - - - - - - - -//
|
||||||
|
<p><a href="./target.md"></a></p>
|
||||||
|
//= = = = = = = = = = = = = = = = = = = = = = = =//
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
8
|
||||||
|
//- - - - - - - - -//
|
||||||
|
[]()
|
||||||
|
//- - - - - - - - -//
|
||||||
|
<p><a href=""></a></p>
|
||||||
|
//= = = = = = = = = = = = = = = = = = = = = = = =//
|
||||||
|
|
@ -42,26 +42,3 @@ func TestSpec(t *testing.T) {
|
||||||
))
|
))
|
||||||
testutil.DoTestCases(markdown, cases, t)
|
testutil.DoTestCases(markdown, cases, t)
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestSpec_EdgeCase_LinkWithEmptyText(t *testing.T) {
|
|
||||||
// TODO: maybe this test cases will be part of the official spec in the future.
|
|
||||||
// check: https://github.com/commonmark/commonmark-spec/issues/636
|
|
||||||
|
|
||||||
cases := []testutil.MarkdownTestCase{
|
|
||||||
testutil.MarkdownTestCase{
|
|
||||||
No: -1,
|
|
||||||
Markdown: "[](./target.md)",
|
|
||||||
Expected: "<p><a href=\"./target.md\"></a></p>",
|
|
||||||
},
|
|
||||||
testutil.MarkdownTestCase{
|
|
||||||
No: -1,
|
|
||||||
Markdown: "[]()",
|
|
||||||
Expected: "<p><a href=\"\"></a></p>",
|
|
||||||
},
|
|
||||||
}
|
|
||||||
markdown := New(WithRendererOptions(
|
|
||||||
html.WithXHTML(),
|
|
||||||
html.WithUnsafe(),
|
|
||||||
))
|
|
||||||
testutil.DoTestCases(markdown, cases, t)
|
|
||||||
}
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue