Example #1
0
        public void Does_DrawBeer_Not_Allow_Draw_When_There_Is_Not_Enough_Beer()
        {
            Keg keg = new Keg(1, string.Empty, 8, 0, 0);
            bool success = keg.DrawBeer(16);

            Assert.IsFalse(success);
            Assert.AreEqual(8, keg.OuncesRemaining);
        }
Example #2
0
        public void Does_DrawBeer_Decrement_Quantity_Correctly_When_There_Is_More_Than_Enough_Beer()
        {
            Keg keg = new Keg(1, string.Empty, 32, 0, 0);
            bool success = keg.DrawBeer(16);

            Assert.IsTrue(success);
            Assert.AreEqual(16, keg.OuncesRemaining);
        }