Update of /cvsroot/mockobjects/mockobjects-java/src/core/com/mockobjects/dynamic
In directory sc8-pr-cvs1:/tmp/cvs-serv20554/src/core/com/mockobjects/dynamic
Modified Files:
Mock.java
Log Message:
Moved all the "core" mock methods to be the last in the series of overloadings. Just to make them easier to find.
Index: Mock.java
===================================================================
RCS file: /cvsroot/mockobjects/mockobjects-java/src/core/com/mockobjects/dynamic/Mock.java,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- Mock.java 21 May 2003 07:57:11 -0000 1.20
+++ Mock.java 8 Jun 2003 00:30:29 -0000 1.21
@@ -144,10 +144,6 @@
this.expectAndReturn(methodName, singleEqualArg, new Integer(result));
}
- public void expectAndReturn(String methodName, ConstraintMatcher args, Object result) {
- callSequence.addExpect(callFactory.createCallExpectation(callFactory.createCallSignature(methodName, args, callFactory.createReturnStub(result))));
- }
-
public void expectAndReturn(String methodName, ConstraintMatcher args, boolean result) {
this.expectAndReturn(methodName, args, new Boolean(result));
}
@@ -156,6 +152,10 @@
this.expectAndReturn(methodName, args, new Integer(result));
}
+ public void expectAndReturn(String methodName, ConstraintMatcher args, Object result) {
+ callSequence.addExpect(callFactory.createCallExpectation(callFactory.createCallSignature(methodName, args, callFactory.createReturnStub(result))));
+ }
+
public void expectAndThrow(String methodName, Throwable exception) {
this.expectAndThrow(methodName, C.NO_ARGS, exception);
}
@@ -200,16 +200,16 @@
this.matchAndReturn(methodName, singleEqualArg, new Integer(result));
}
- public void matchAndReturn(String methodName, ConstraintMatcher args, Object result) {
- callSequence.addMatch(callFactory.createCallSignature(methodName, args, callFactory.createReturnStub(result)));
- }
-
public void matchAndReturn(String methodName, ConstraintMatcher args, boolean result) {
this.matchAndReturn(methodName, args, new Boolean(result));
}
public void matchAndReturn(String methodName, ConstraintMatcher args, int result) {
this.matchAndReturn(methodName, args, new Integer(result));
+ }
+
+ public void matchAndReturn(String methodName, ConstraintMatcher args, Object result) {
+ callSequence.addMatch(callFactory.createCallSignature(methodName, args, callFactory.createReturnStub(result)));
}
public void matchAndThrow(String methodName, Throwable throwable) {
|