示例#1
0
        public void WhenVehicleUsesPetrolAndPriceIsOver40K()
        {
            Vehicle vehicle = new Vehicle(206, FuelType.Petrol, FirstOfApril2017, 50000);
            int     tax     = _taxCalculator.CalculateTax(vehicle, false, true);

            Assert.AreEqual(450, tax);
        }
示例#2
0
        public void WhenVehicleUsesPetrol()
        {
            Vehicle vehicle = new Vehicle(206, FuelType.Petrol, FirstOfApril2017, 20000);
            int     tax     = _taxCalculator.CalculateTax(vehicle, true);

            Assert.AreEqual(140, tax);
        }
        public void WhenVehicleHas0GramsCo2()
        {
            Vehicle vehicle = new Vehicle(0, FuelType.Petrol, FirstOfJanuary2019, 20000);
            int     tax     = _taxCalculator.CalculateTax(vehicle);

            Assert.AreEqual(0, tax);
        }