public void VaMuyBien()
        {
            var calculator = new TokidokiFacturator();

            Assert.IsTrue(calculator.calcular(0, 0) == 0);
            Assert.IsTrue(calculator.calcular(-5, 0) == 0);
        }
        public void GivenTheTwoTokidokisWorks_WhenCalculate_ThenHaveTheCorrectNumerOfBeers()
        {
            // Arrange
            var unicornHours   = 5;
            var donatellaHours = 3;

            // Action
            var beers = calculator.calcular(unicornHours, donatellaHours);

            // Assert
            Assert.AreEqual(18, beers);
        }
        public void GivenTheTwoTokidokisWorks_WhenCalculate_ThenHaveTheCorrectNumerOfBeers()
        {
            // Arrange
            var unicornHours   = 5;
            var donatellaHours = 3;

            mockBeersHour.Setup(b => b.BeersUnicorn()).Returns(3);
            mockBeersHour.Setup(b => b.BeersDonatella()).Returns(1);

            // Action
            var beers = calculator.calcular(unicornHours, donatellaHours);

            // Assert
            Assert.AreEqual(18, beers);
        }
Beispiel #4
0
        public void GivenTokidokisWorksInNegative_WhenCalculate_ThenAreNoBeers()
        {
            // Arrange
            var unicornHours   = -5;
            var donatellaHours = 0;
            var calculator     = new TokidokiFacturator();

            // Action
            var beers = calculator.calcular(unicornHours, donatellaHours);

            // Assert
            Assert.AreEqual(0, beers);
        }
        public void VaBien()
        {
            var calculator = new TokidokiFacturator();

            Assert.IsTrue(calculator.calcular(5, 3) == 18);
        }