35
readFile();
}
Question 2 (5 points):
The following Java method calculates the total price for a customer's order based on item prices,customer type, a discount code, and whether the customer is a VIP. The method involves different calculations for various discount scenarios. Your task is to design test cases using JUnit for this method. You should apply equivalence partitioning and boundary value analysis for the input parameters. Additionally, ensure that your test cases cover all branches of the code to achieve 100% code coverage.
public class OrderCalculator (
2
Zoom
+ 100%
Close