Example #1
0
        public void UpdateStatusAndStartCountingRepairementHoursForLightMalfunctionVehicle(int checkVehicleStatusTimeInSeconds, int raceTotalDistance)
        {
            var vehicle = VehicleBuilder.BuildWithTypeAndStatus(VehicleType.CrossMotorcycle, VehicleStatus.LightMalfunction);

            var actual = vehicle.UpdateStatus(checkVehicleStatusTimeInSeconds, raceTotalDistance);

            actual.Status.Should().Be(VehicleStatus.LightMalfunction);
            actual.Distance.Should().Be(vehicle.Distance);
            actual.RepairmentHours.Should().Be(1);
        }