My favorites | Sign in
Project Home Downloads Wiki Issues Source
Checkout   Browse   Changes    
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package com.kirkk.test;

import junit.framework.TestCase;
import java.math.BigDecimal;
import java.util.*;
import com.kirkk.cust.*;
import com.kirkk.bill.*;

public class PaymentTest extends TestCase {

public PaymentTest(String arg0) {
super(arg0);
}

public static void main(String[] args) {
}

protected void setUp() throws Exception {

}

public void testPayment() {

Customer customer = new Customer();
customer.createBill(new BigDecimal(500));

Iterator bills = customer.getBills().iterator();

while (bills.hasNext()) {
Bill bill = (Bill) bills.next();
BigDecimal paidAmount = bill.pay();
assertEquals("Paid amount not correct.", new BigDecimal(485).setScale(2), paidAmount);
}
}

}

Change log

r75 by pragkirk on Nov 18, 2009   Diff
Initial Version
Go to: 
Project members, sign in to write a code review

Older revisions

All revisions of this file

File info

Size: 755 bytes, 36 lines

File properties

svn:executable
Powered by Google Project Hosting