예제 #1
0
        private static void TestValidCoinCreation(string description, decimal expectedValue)
        {
            ValidCoin validCoin;
            var       success = ValidCoin.TryCreate(description, out validCoin);

            Assert.That(success, Is.EqualTo(true));
            Assert.That(validCoin.Value, Is.EqualTo(expectedValue));
        }
예제 #2
0
        private static void TestCoinCreationWithInvalidDescription(string description)
        {
            ValidCoin validCoin;
            var       success = ValidCoin.TryCreate(description, out validCoin);

            Assert.That(success, Is.EqualTo(false));
            Assert.That(validCoin, Is.EqualTo(null));
        }