JUnit Exercise
Given the
Javadoc for the following class write a JUnit test case for inflate().
|
Constructor Detail |
public
Tire()
Creates a tire with:
Pressure = 35 PSI
public
int getPressure()
Determines the current tire pressure.
Returns:
int the current tire pressure 0 - 55 PSI (inclusive)
public
void inflate(int amount)
Inflates or deflates the tire by the specified amount in
PSI.
Parameters:
amount - to change tire inflation in PSI. Regardless of input the tire can only deflate or inflate to a minimum of 0 PSI and maximum of 55 PSI.