Example #1
0
        public void TestSomethingIsReturned()
        {
            var atmBase   = new AtmBase();
            var testValue = atmBase.CalculateBills(100);

            Assert.IsNotNull(testValue);
        }
Example #2
0
        public void TestOnlyTwentiesAreReturned()
        {
            var atmBase   = new AtmBase();
            var testValue = atmBase.CalculateBills(60);

            var expectedValue = new ReturnedBills
            {
                Hundreds = 0,
                Fifties  = 0,
                Twenties = 3
            };

            Assert.AreEqual(testValue.Hundreds, expectedValue.Hundreds);
            Assert.AreEqual(testValue.Fifties, expectedValue.Fifties);
            Assert.AreEqual(testValue.Twenties, expectedValue.Twenties);
        }
Example #3
0
        public void TestCorrectValueIsReturned()
        {
            var atmBase   = new AtmBase();
            var testValue = atmBase.CalculateBills(170);

            var expectedValue = new ReturnedBills
            {
                Hundreds = 1,
                Fifties  = 1,
                Twenties = 1
            };

            Assert.AreEqual(testValue.Hundreds, expectedValue.Hundreds);
            Assert.AreEqual(testValue.Fifties, expectedValue.Fifties);
            Assert.AreEqual(testValue.Twenties, expectedValue.Twenties);
        }