示例#1
0
 public void TestValidateValidDate()
 {
     QslSDate date = new QslSDate("19990615");
     string err = string.Empty;
     string modStr = string.Empty;
     Assert.IsTrue(date.Validate(out err, out modStr));
     Assert.IsNull(err);
     Assert.IsNull(modStr);
 }
示例#2
0
 public void TestValidateInvalidDate()
 {
     QslSDate date = new QslSDate("19250615");
     string err = string.Empty;
     string modStr = string.Empty;
     Assert.IsFalse(date.Validate(out err, out modStr));
     Assert.AreEqual("\tDate must be 19300101 or later.", err);
     Assert.IsNull(modStr);
 }