@@ -2466,6 +2466,66 @@ I am paragraph number three.</summary>
2466
2466
TestWithStrings ( originalIntellisense , originalDocs , expectedDocs , configuration ) ;
2467
2467
}
2468
2468
2469
+ [ Fact ]
2470
+ public void Convert_DataDevCommentType_To_ExpectedElementNames ( )
2471
+ {
2472
+ // The compiled xml files sometimes generate langwords, paramrefs and typeparamrefs with the format
2473
+ // <code data-dev-comment-type="...">...</code>, so we need to convert them to the expected element type.
2474
+
2475
+ string originalIntellisense = @"<?xml version=""1.0""?>
2476
+ <doc>
2477
+ <assembly>
2478
+ <name>MyAssembly</name>
2479
+ </assembly>
2480
+ <members>
2481
+ <member name=""T:MyNamespace.MyType"">
2482
+ <summary>Langword <code data-dev-comment-type=""langword"">true</code>. Paramref <code data-dev-comment-type=""paramref"">myParam</code>. Typeparamref <code data-dev-comment-type=""typeparamref"">myTypeParam</code>.</summary>
2483
+ <remarks>Langword <code data-dev-comment-type=""langword"">true</code>. Paramref <code data-dev-comment-type=""paramref"">myParam</code>. Typeparamref <code data-dev-comment-type=""typeparamref"">myTypeParam</code>.</remarks>
2484
+ </member>
2485
+ </members>
2486
+ </doc>" ;
2487
+
2488
+ string originalDocs = @"<Type Name=""MyType"" FullName=""MyNamespace.MyType"">
2489
+ <TypeSignature Language=""DocId"" Value=""T:MyNamespace.MyType"" />
2490
+ <AssemblyInfo>
2491
+ <AssemblyName>MyAssembly</AssemblyName>
2492
+ </AssemblyInfo>
2493
+ <Docs>
2494
+ <summary>To be added.</summary>
2495
+ <remarks>To be added.</remarks>
2496
+ </Docs>
2497
+ <Members></Members>
2498
+ </Type>" ;
2499
+
2500
+ string expectedDocs = @"<Type Name=""MyType"" FullName=""MyNamespace.MyType"">
2501
+ <TypeSignature Language=""DocId"" Value=""T:MyNamespace.MyType"" />
2502
+ <AssemblyInfo>
2503
+ <AssemblyName>MyAssembly</AssemblyName>
2504
+ </AssemblyInfo>
2505
+ <Docs>
2506
+ <summary>Langword <see langword=""true"" />. Paramref <see paramref=""myParam"" />. Typeparamref <see typeparamref=""myTypeParam"" />.</summary>
2507
+ <remarks>
2508
+ <format type=""text/markdown""><![CDATA[
2509
+
2510
+ ## Remarks
2511
+
2512
+ Langword `true`. Paramref `myParam`. Typeparamref `myTypeParam`.
2513
+
2514
+ ]]></format>
2515
+ </remarks>
2516
+ </Docs>
2517
+ <Members></Members>
2518
+ </Type>" ;
2519
+
2520
+ Configuration configuration = new ( )
2521
+ {
2522
+ MarkdownRemarks = true
2523
+ } ;
2524
+ configuration . IncludedAssemblies . Add ( FileTestData . TestAssembly ) ;
2525
+
2526
+ TestWithStrings ( originalIntellisense , originalDocs , expectedDocs , configuration ) ;
2527
+ }
2528
+
2469
2529
private static void TestWithStrings ( string intellisenseFile , string originalDocsFile , string expectedDocsFile , Configuration configuration ) =>
2470
2530
TestWithStrings ( intellisenseFile , new List < StringTestData > ( ) { new StringTestData ( originalDocsFile , expectedDocsFile ) } , configuration ) ;
2471
2531
0 commit comments