Exemplo n.º 1
0
        public void TestHoursB()
        {
            //Arrange
            int rentMinutes = 23;
            //0 hour 23 minutes according to the requirements should be considered 1 hour
            int expected = 1;

            //Act
            int actual = CostCalculationsHelper.TotalHours(rentMinutes);

            //Assert
            Assert.AreEqual(expected, actual);
        }
Exemplo n.º 2
0
        public void TestHoursA()
        {
            //Arrange
            int rentMinutes = 123;

            //123 minutes is equivalent to 2hours 3 minutes which according to the requirements should be considered 3 hours
            int expected = 3;

            //Act
            int actual = CostCalculationsHelper.TotalHours(rentMinutes);

            //Assert
            Assert.AreEqual(expected, actual);
        }
Exemplo n.º 3
0
        public void TestHoursC()
        {
            //Arrange
            int rentMinutes = 500;

            //8 hours 20minutes according to the requirements should be considered 9 hours
            int expected = 9;

            //Act
            int actual = CostCalculationsHelper.TotalHours(rentMinutes);

            //Assert
            Assert.AreEqual(expected, actual);
        }