Class AbstractRequestExpectationManager.RequestExpectationGroup
java.lang.Object
org.springframework.test.web.client.AbstractRequestExpectationManager.RequestExpectationGroup
- Enclosing class:
- AbstractRequestExpectationManager
Helper class to manage a group of remaining expectations.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addAllExpectations
(Collection<RequestExpectation> expectations) findExpectation
(ClientHttpRequest request) Return a matching expectation, ornull
if none match.void
reset()
Reset all expectations for this group.void
update
(RequestExpectation expectation) Invoke this for an expectation that has been matched.
-
Constructor Details
-
RequestExpectationGroup
protected RequestExpectationGroup()
-
-
Method Details
-
addAllExpectations
-
getExpectations
-
findExpectation
Return a matching expectation, ornull
if none match.- Throws:
IOException
-
update
Invoke this for an expectation that has been matched.The count of the given expectation is incremented, then it is either stored if remainingCount > 0 or removed otherwise.
-
reset
public void reset()Reset all expectations for this group.
-