@@ -115,6 +115,7 @@ public class ExternalLinkReferenceTest(ITestOutputHelper output) : LinkTestBase(
115115 public void GeneratesHtml ( ) =>
116116 // language=html
117117 Html . Should ( ) . Contain (
118+ // TODO: The link is not rendered correctly yet, will be fixed in a follow-up
118119 """<p><a href="kibana://index.html">test</a></p>"""
119120 ) ;
120121
@@ -139,6 +140,7 @@ public class ExternalLinkTest(ITestOutputHelper output) : LinkTestBase(output,
139140 public void GeneratesHtml ( ) =>
140141 // language=html
141142 Html . Should ( ) . Contain (
143+ // TODO: The link is not rendered correctly yet, will be fixed in a follow-up
142144 """<p><a href="kibana://index.html">test</a></p>"""
143145 ) ;
144146
@@ -153,4 +155,35 @@ public void EmitsExternalLink()
153155 }
154156}
155157
158+ public class DuplicateExternalLinkTest ( ITestOutputHelper output ) : LinkTestBase ( output ,
159+ """
160+ [a](kibana://index.md)
161+ [b](kibana://index.md)
162+ [c](elasticsearch://index.md)
163+ """
164+ )
165+ {
166+ [ Fact ]
167+ public void GeneratesHtml ( ) =>
168+ // language=html
169+ Html . Should ( ) . Contain (
170+ // TODO: The link is not rendered correctly yet, will be fixed in a follow-up
171+ """
172+ <p><a href="kibana://index.html">a</a><br />
173+ <a href="kibana://index.html">b</a><br />
174+ <a href="elasticsearch://index.html">c</a></p>
175+ """
176+ ) ;
177+
178+ [ Fact ]
179+ public void HasNoErrors ( ) => Collector . Diagnostics . Should ( ) . HaveCount ( 0 ) ;
180+
181+ [ Fact ]
182+ public void EmitsExternalLink ( )
183+ {
184+ Collector . ExternalLinks . Should ( ) . HaveCount ( 2 ) ;
185+ Collector . ExternalLinks . Should ( ) . ContainKey ( "kibana://index.md" ) ;
186+ Collector . ExternalLinks . Should ( ) . ContainKey ( "elasticsearch://index.md" ) ;
187+ }
188+ }
156189
0 commit comments