Add comment parsing test

This commit is contained in:
Nathan McRae 2024-02-14 18:32:31 -08:00
parent 6cea9b7e59
commit e52dc01e7a

View File

@ -34,5 +34,19 @@ using System.Text;
Console.WriteLine($"Passed {testName}"); Console.WriteLine($"Passed {testName}");
} }
Console.WriteLine("Done with tests");
} }
{
string testName = "Comment test";
string testString1 = "#This is a file comment\n" +
" #One more file comment line\n" +
"column1:type:boolean\tcolumn2:binary\tcolumnthree\\nyep:string" +
"\n#This is a comment" +
"\n#Another comment line" +
"\nTRUE\tvalue\\\\t\0woo\tvaluetrhee" +
"\nFALSE\tnother\tno\\ther";
SaneTsv parsed = SaneTsv.ParseCommentedTsv(Encoding.UTF8.GetBytes(testString1));
}
Console.WriteLine("Done with tests");