Browse Source

Updated a test to properly check the new printing of comments.

Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
pull/778/head
Dimitar Dobrev 9 years ago
parent
commit
02b845e6b0
  1. 36
      src/Generator.Tests/AST/TestAST.cs

36
src/Generator.Tests/AST/TestAST.cs

@ -390,24 +390,24 @@ namespace CppSharp.Generator.Tests.AST
var method = @class.Methods.First(m => m.Name == "GetIOHandlerControlSequence"); var method = @class.Methods.First(m => m.Name == "GetIOHandlerControlSequence");
var commentMethod = method.Comment.FullComment.CommentToString(CommentKind.BCPL); var commentMethod = method.Comment.FullComment.CommentToString(CommentKind.BCPL);
Assert.AreEqual(@"/// <summary> Assert.AreEqual(@"// <summary>
/// <para>Get the string that needs to be written to the debugger stdin file</para> // <para>Get the string that needs to be written to the debugger stdin file</para>
/// <para>handle when a control character is typed.</para> // <para>handle when a control character is typed.</para>
/// </summary> // </summary>
/// <remarks> // <remarks>
/// <para>Some GUI programs will intercept &quot;control + char&quot; sequences and want</para> // <para>Some GUI programs will intercept &quot;control + char&quot; sequences and want</para>
/// <para>to have them do what normally would happen when using a real</para> // <para>to have them do what normally would happen when using a real</para>
/// <para>terminal, so this function allows GUI programs to emulate this</para> // <para>terminal, so this function allows GUI programs to emulate this</para>
/// <para>functionality.</para> // <para>functionality.</para>
/// </remarks> // </remarks>
/// <param name=""ch""> // <param name=""ch"">
/// <para>The character that was typed along with the control key</para> // <para>The character that was typed along with the control key</para>
/// </param> // </param>
/// <returns> // <returns>
/// <para>The string that should be written into the file handle that is</para> // <para>The string that should be written into the file handle that is</para>
/// <para>feeding the input stream for the debugger, or NULL if there is</para> // <para>feeding the input stream for the debugger, or NULL if there is</para>
/// <para>no string for this control key.</para> // <para>no string for this control key.</para>
/// </returns>".Replace("\r", string.Empty), commentMethod.Replace("\r", string.Empty)); // </returns>".Replace("\r", string.Empty), commentMethod.Replace("\r", string.Empty));
} }
[Test] [Test]

Loading…
Cancel
Save