예제 #1
0
        public void Test_TryParseDecimal_InvalidFormat(string jsonData)
        {
            decimal value;
            bool    res = CsvValueParser.TryParseDecimal(jsonData, out value);

            Assert.That(res, Is.False);
        }
예제 #2
0
        public void Test_TryParseDecimal_Valid(string jsonData, double expectedData)
        {
            decimal expected = (decimal)expectedData;
            decimal value;
            bool    res = CsvValueParser.TryParseDecimal(jsonData, out value);

            Assert.That(res, Is.True);
            Assert.That(value, Is.EqualTo(expected));
        }