public void LineBreakInField() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(3, "1,\"2\n3\",4").IsValid); }
public void SpecifiedDelimiter() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(3, "1;2;3", delimiter: ';').IsValid); }
public void SpecifiedQuoteChar() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(3, "1,`2,3`,4", textQualifier: '`').IsValid); }
public void FieldEndsWithEscapedDoubleQuote() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(1, @"""--""""""").IsValid); }
public void OneTwoOrThreeEscapedDoubleQuotesInStrings() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(3, "\"\"\"\",\"\"\"\"\"\",\"\"\"\"\"\"\"\"").IsValid); }
public void EmptyRecordNotIngored() { Assert.IsFalse(DelimitedStringValidator.ValidateFormat(4, "").IsValid); }
public void EscapedQuote() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(3, @"1,""2""""3"",4").IsValid); }
public void LeadingEmptyField() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(4, ",1,2,3").IsValid); }
public void EmptyRecordIgnored() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(4, "", ignoreEmptyLines: true).IsValid); }
public void QuotedStrings() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(3, "Lorem,\"ipsum, dolor, sit\",amet").IsValid); }
public void TrailingEmptyField() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(4, "1,2,3,").IsValid); }
public void BasicStrings() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(5, "adipisicing,elit,sed,do,eiusmod").IsValid); }
public void FieldBeginsWithComma() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(1, "\",a\"").IsValid); }
public void TwoBlankFields() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(2, ",").IsValid); }
public void SpacesInFields() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(4, ", 1 ,\" 2 \",").IsValid); }
public void BasicNumbers() { Assert.IsTrue(DelimitedStringValidator.ValidateFormat(3, "1,2,3").IsValid); }