示例#1
0
 public void TestInvalidKontonummerWrongLength()
 {
     try
     {
         KontonummerValidator.ValidateSyntax("123456789012");
         Assert.True(false);
     }
     catch (ArgumentException e)
     {
         AssertionUtils.AssertMessageContains(e, StringNumberValidator.ERROR_SYNTAX);
     }
 }
示例#2
0
 public void TestInvalidKontonummerNotDigits()
 {
     try
     {
         KontonummerValidator.ValidateSyntax("abcdefghijk");
         Assert.True(false);
     }
     catch (ArgumentException e)
     {
         AssertionUtils.AssertMessageContains(e, StringNumberValidator.ERROR_SYNTAX);
     }
 }
 public void TestInvalidKontonummer(string kontoNr, string description)
 {
     try
     {
         KontonummerValidator.ValidateSyntax(kontoNr);
         Assert.Fail(description);
     }
     catch (ArgumentException e)
     {
         AssertionUtils.AssertMessageContains(e, StringNumberValidator.SyntaxErrorMessage);
     }
 }