Package org.jmock.expectation
Class ExpectationSet
- java.lang.Object
-
- org.jmock.expectation.AbstractExpectation
-
- org.jmock.expectation.AbstractExpectationCollection
-
- org.jmock.expectation.ExpectationSet
-
- All Implemented Interfaces:
Verifiable
,Expectation
,ExpectationCollection
public class ExpectationSet extends AbstractExpectationCollection
-
-
Field Summary
-
Fields inherited from class org.jmock.expectation.AbstractExpectation
myFailureModeIsImmediate, myName
-
-
Constructor Summary
Constructors Constructor Description ExpectationSet(java.lang.String name)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
checkImmediateValues(java.lang.Object actualItem)
protected java.util.Collection
getActualCollection()
protected java.util.Collection
getExpectedCollection()
void
verify()
Throw an AssertionFailedException if any expectations have not been met.-
Methods inherited from class org.jmock.expectation.AbstractExpectationCollection
addActual, addActual, addActual, addActualMany, addActualMany, addActualMany, addExpected, addExpected, addExpected, addExpectedMany, addExpectedMany, addExpectedMany, clearActual, clearExpectation, setExpectNothing
-
Methods inherited from class org.jmock.expectation.AbstractExpectation
assertEquals, assertEquals, hasExpectations, setFailOnVerify, setHasExpectations, shouldCheckImmediately
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jmock.expectation.Expectation
hasExpectations, setFailOnVerify
-
-
-
-
Method Detail
-
checkImmediateValues
protected void checkImmediateValues(java.lang.Object actualItem)
- Specified by:
checkImmediateValues
in classAbstractExpectationCollection
-
getActualCollection
protected java.util.Collection getActualCollection()
- Specified by:
getActualCollection
in classAbstractExpectationCollection
-
getExpectedCollection
protected java.util.Collection getExpectedCollection()
- Specified by:
getExpectedCollection
in classAbstractExpectationCollection
-
verify
public void verify()
Description copied from interface:Verifiable
Throw an AssertionFailedException if any expectations have not been met. Implementations of this method must be idempotent: jMock can call this method more than once when verifying expectations at the end of a test.- Specified by:
verify
in interfaceVerifiable
- Overrides:
verify
in classAbstractExpectationCollection
-
-