Question: this needs to run in Eclipse Java Photon Unit Test In-class Lab Problem Statement A parking garage charges a $2.00 minimum fee to park for

this needs to run in Eclipse Java Photon

Unit Test In-class Lab Problem Statement A parking garage charges a $2.00 minimum fee to park for up to three hours. The garage charges an additional $0.50 per hour for each hour of part thereof in excess of three hours. The maximum charge for any given 24-hour period is $10.00. Assume that no car parks for longer than 24 hours. Lab Activity Objective: Practice the test-first methodology using JUnit to perform unit testing. Pre-lab activities: If you havent already, download and install the latest version of Eclipse. Activities: 1. Create a ParkingCharges class with a calcParkingCharges() method.

a. Create a Junit test to validate minimum charge.

b. Configure calcParkingCharges() to return the minimum charge (hours <= 3).

c. Add a statement/statements to the Junit test to validate charges between the minimum and maximum charges.

d. Configure calcParkingCharges() to return charges between the minimum and maximum charge.

e. Add a statement/statements to the Junit test to validate maximum charge.

f. Configure calcParkingCharges() to return the maximum charge.

2. Create a ParkingChargesApp class that calculates and displays the parking charges for each customer who parked in the garage and displays the running total of the days receipts.

a. Enter the hours parked.

b. Display the charges for this customer.

c. Display the running total.

d. Continue as long as there is another customer.

this needs to run in Eclipse Java Photon

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!