river-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tho...@apache.org
Subject svn commit: r770816 - in /incubator/river/jtsk/trunk/test: lib/easymock.jar lib/easymockclassextension.jar lib/mockito-all-1.7.jar src/com/sun/jini/outrigger/TxnTableTest.java
Date Fri, 01 May 2009 20:30:21 GMT
Author: thobbs
Date: Fri May  1 20:30:20 2009
New Revision: 770816

URL: http://svn.apache.org/viewvc?rev=770816&view=rev
Log:
Changed unit test (and uploaded JARs) away from EasyMock and onto Mockito as agreed on dev
list

Added:
    incubator/river/jtsk/trunk/test/lib/mockito-all-1.7.jar   (with props)
Removed:
    incubator/river/jtsk/trunk/test/lib/easymock.jar
    incubator/river/jtsk/trunk/test/lib/easymockclassextension.jar
Modified:
    incubator/river/jtsk/trunk/test/src/com/sun/jini/outrigger/TxnTableTest.java

Added: incubator/river/jtsk/trunk/test/lib/mockito-all-1.7.jar
URL: http://svn.apache.org/viewvc/incubator/river/jtsk/trunk/test/lib/mockito-all-1.7.jar?rev=770816&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/river/jtsk/trunk/test/lib/mockito-all-1.7.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: incubator/river/jtsk/trunk/test/src/com/sun/jini/outrigger/TxnTableTest.java
URL: http://svn.apache.org/viewvc/incubator/river/jtsk/trunk/test/src/com/sun/jini/outrigger/TxnTableTest.java?rev=770816&r1=770815&r2=770816&view=diff
==============================================================================
--- incubator/river/jtsk/trunk/test/src/com/sun/jini/outrigger/TxnTableTest.java (original)
+++ incubator/river/jtsk/trunk/test/src/com/sun/jini/outrigger/TxnTableTest.java Fri May 
1 20:30:20 2009
@@ -24,7 +24,7 @@
 import net.jini.core.transaction.server.TransactionManager;
 import junit.framework.TestCase;
 
-import static org.easymock.classextension.EasyMock.*;
+import static org.mockito.Mockito.*;
 
 public class TxnTableTest extends TestCase {
 
@@ -47,11 +47,9 @@
 	@SuppressWarnings("unchecked")
 	public void testKeyEquals() throws Exception {
 		
-		TxnTable mockTxnTable = createNiceMock(TxnTable.class);
-		replay(mockTxnTable);
+		TxnTable mockTxnTable = mock(TxnTable.class);
 		
-		TransactionManager mockTransactionManager = createNiceMock(TransactionManager.class);
-		replay(mockTransactionManager);
+		TransactionManager mockTransactionManager = mock(TransactionManager.class);
 		
 		final long id = 1000L;
 		final boolean isPrepared = true;



Mime
View raw message