public void IncomeTaxIsCalculatedProperlyForProperData(decimal hours, decimal rate, decimal expected) { // Arrange var sut = new GermanySalaryCalculator { GrossAmount = hours * rate }; // Act var result = sut.CalculateIncomeTax(); // Assert Assert.AreEqual(expected, result); }
public void IncomeTaxIsEqualZeroWhenHoursOrRateIsNegative(decimal hours, decimal rate) { // Arrange var sut = new GermanySalaryCalculator { GrossAmount = hours * rate }; decimal expected = 0; // Act var result = sut.CalculateIncomeTax(); // Assert Assert.AreEqual(expected, result); }