Stuff
public text v1 · immutablepackage model;
import junit.framework.*;
public class CashBoxTest extends TestCase {
public CashBoxTest(String testName) {
super(testName);
}
public void testMakeDeposit () {
CashBox c = new CashBox();
int testDeposit = 4000;
int testPrice = 3999;
int expectedExchange = 1;
c.makeDeposit(testDeposit, testPrice);
if(!c.getInfo().equalsIgnoreCase("\nPrice: " + testPrice + "\nPayment: " + testDeposit + "\nExchange: " + expectedExchange)) {
fail("Method makeDeposit failed!");
}
}
}