svn commit: r601667 - /ofbiz/branches/release4.0/applications/accounting/src/org/ofbiz/accounting/test/FinAccountTests.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r601667 - /ofbiz/branches/release4.0/applications/accounting/src/org/ofbiz/accounting/test/FinAccountTests.java

lektran
Author: lektran
Date: Thu Dec  6 01:24:46 2007
New Revision: 601667

URL: http://svn.apache.org/viewvc?rev=601667&view=rev
Log:
Fixed some backpatched java 1.5 code to be compatible with java 1.4, reported by Bilgin Ibryam

Modified:
    ofbiz/branches/release4.0/applications/accounting/src/org/ofbiz/accounting/test/FinAccountTests.java

Modified: ofbiz/branches/release4.0/applications/accounting/src/org/ofbiz/accounting/test/FinAccountTests.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/release4.0/applications/accounting/src/org/ofbiz/accounting/test/FinAccountTests.java?rev=601667&r1=601666&r2=601667&view=diff
==============================================================================
--- ofbiz/branches/release4.0/applications/accounting/src/org/ofbiz/accounting/test/FinAccountTests.java (original)
+++ ofbiz/branches/release4.0/applications/accounting/src/org/ofbiz/accounting/test/FinAccountTests.java Thu Dec  6 01:24:46 2007
@@ -68,8 +68,8 @@
         ctx.put("amount", new Double(100.00));
         ctx.put("userLogin", userLogin);
         Map resp = dispatcher.runSync("finAccountDeposit", ctx);
-        Double balance = ((Double) resp.get("balance")).doubleValue();
-        assertEquals(balance, 100.00, 0.0);
+        Double balance = (Double) resp.get("balance");
+        assertEquals(balance.doubleValue(), 100.00, 0.0);
     }
 
     public void testWithdraw() throws Exception {
@@ -79,7 +79,7 @@
         ctx.put("userLogin", userLogin);
         Map resp = dispatcher.runSync("finAccountWithdraw", ctx);
         Double previousBalance = (Double) resp.get("previousBalance");
-        Double balance = ((Double) resp.get("balance")).doubleValue();
-        assertEquals((balance + 50.00), previousBalance.doubleValue(), 0.0);
+        Double balance = (Double) resp.get("balance");
+        assertEquals((balance.doubleValue() + 50.00), previousBalance.doubleValue(), 0.0);
     }
 }