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); }
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); }
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); }