示例#1
0
 public void TestValidateInvalidHHMMS()
 {
     Time_On tf = new Time_On("12345");
     string err = string.Empty;
     string modStr = string.Empty;
     Assert.IsFalse(tf.Validate(out err, out modStr));
     Assert.AreEqual("\tTime must be in HHMM or HHMMSS format.", err);
     Assert.IsNull(modStr);
 }
示例#2
0
 public void TestValidateInvalidHour()
 {
     Time_On tf = new Time_On("243456");
     string err = string.Empty;
     string modStr = string.Empty;
     Assert.IsFalse(tf.Validate(out err, out modStr));
     Assert.AreEqual("\tInvalid time.", err);
     Assert.IsNull(modStr);
 }
示例#3
0
 public void TestValidateValidHHMMSS()
 {
     Time_On tf = new Time_On("123456");
     string err = string.Empty;
     string modStr = string.Empty;
     Assert.IsTrue(tf.Validate(out err, out modStr));
     Assert.IsNull(err);
     Assert.IsNull(modStr);
 }