Esempio n. 1
0
        public void AccountIdIsPositiveIntegerExpectSuccess()
        {
            MeterCsvValidator validator = new MeterCsvValidator();

            Assert.IsTrue(validator.TryParseAccountId("78", out int accountId));
            Assert.AreEqual(78, accountId);
        }
Esempio n. 2
0
        public void AccountIdIsNotANumberExpectFailure()
        {
            MeterCsvValidator validator = new MeterCsvValidator();

            Assert.IsFalse(validator.TryParseAccountId("ABC", out int accountId));
        }
Esempio n. 3
0
        public void AccountIdIsDecimalExpectFailure()
        {
            MeterCsvValidator validator = new MeterCsvValidator();

            Assert.IsFalse(validator.TryParseAccountId("78.45", out int accountId));
        }
Esempio n. 4
0
        public void AccountIdIsNegativeIntegerExpectFailure()
        {
            MeterCsvValidator validator = new MeterCsvValidator();

            Assert.IsFalse(validator.TryParseAccountId("-78", out int accountId));
        }