public void TestValidateFreqOutsideBands() { Freq_Rx freq = new Freq_Rx("14.463", aEnums); string err = string.Empty; string modStr = string.Empty; Assert.IsFalse(freq.Validate(out err, out modStr)); Assert.AreEqual("\t'14.463' is outside enumerated band limits.", err); Assert.IsNull(modStr); }
public void TestValidateValidFreq() { Freq_Rx freq = new Freq_Rx("14.235", aEnums); string err = string.Empty; string modStr = string.Empty; Assert.IsTrue(freq.Validate(out err, out modStr)); Assert.IsNull(err); Assert.IsNull(modStr); }
public void TestValidateFreqNonNumber2() { Freq_Rx freq = new Freq_Rx("14.235F", aEnums); string err = string.Empty; string modStr = string.Empty; Assert.IsFalse(freq.Validate(out err, out modStr)); Assert.AreEqual("\tValue must be a number.", err); Assert.IsNull(modStr); }