public abstract class AbstractClientServerIntegrationTest extends Object
Modifier and Type | Field and Description |
---|---|
protected List<String> |
headersToIgnore |
protected static MockServerClient |
mockServerClient |
protected static String |
servletContext |
protected static String |
TEXT_PLAIN |
Constructor and Description |
---|
AbstractClientServerIntegrationTest() |
protected static final String TEXT_PLAIN
protected static MockServerClient mockServerClient
protected static String servletContext
public static Expectation expectation(HttpRequest httpRequest)
public abstract int getMockServerPort()
public abstract int getMockServerSecurePort()
public abstract int getTestServerPort()
public void resetServer()
public void shouldForwardRequestInHTTP()
public void shouldForwardRequestInHTTPS()
public void shouldForwardTemplateInVelocity()
public void shouldAllowSimultaneousForwardAndResponseExpectations()
public void shouldCallbackToSpecifiedClassWithPrecannedResponse()
public void shouldReturnResponseWithOnlyBody()
public void shouldSupportBatchedExpectations()
public void shouldReturnResponseForRequestInSsl()
public void shouldReturnResponseForRequestNotInSsl()
public void shouldReturnMatchRequestWithBodyInUTF16()
public void shouldReturnMatchRequestWithBodyInUTF16WithContentTypeHeader()
public void shouldReturnResponseWithBodyInUTF8()
public void shouldReturnResponseWithBodyInUTF16WithContentTypeHeader()
public void shouldReturnResponseWithOnlyStatusCode()
public void shouldReturnResponseByMatchingPath()
public void shouldReturnResponseByMatchingPathExactTimes()
public void shouldReturnResponseWhenTimeToLiveHasNotExpired()
public void shouldReturnResponseByMatchingBodyWithXPath()
public void shouldReturnResponseByMatchingBodyWithXml()
public void shouldReturnResponseByMatchingBodyWithJson()
public void shouldReturnResponseByMatchingBodyWithJsonWithCharsetUTF8()
public void shouldReturnResponseByMatchingBodyWithJsonWithContentTypeHeader()
public void shouldReturnResponseByMatchingBodyWithJsonWithMatchType()
public void shouldReturnResponseByMatchingBodyWithJsonSchema()
public void shouldReturnResponseByMatchingBodyWithXmlSchema()
public void shouldReturnResponseByMatchingBodyWithXmlSchemaByClasspath()
public void shouldReturnPDFResponseByMatchingPath() throws IOException
IOException
public void shouldReturnPNGResponseByMatchingPath() throws IOException
IOException
public void shouldReturnPDFResponseByMatchingBinaryPDFBody() throws IOException
IOException
public void shouldReturnPNGResponseByMatchingBinaryPNGBody() throws IOException
IOException
public void shouldReturnResponseForExpectationWithDelay()
public void shouldReturnResponseFromVelocityTemplate()
public void shouldReturnResponseByMatchingPathAndMethod()
public void shouldReturnResponseByNotMatchingPathWithNotOperator()
public void shouldReturnResponseByNotMatchingMethodWithNotOperator()
public void shouldReturnResponseByMatchingPathAndMethodAndBody()
public void shouldReturnResponseByMatchingPathAndMethodAndQueryStringParameters()
public void shouldReturnResponseByMatchingPathAndMethodAndHeaders()
public void shouldReturnResponseByMatchingPathAndMethodAndCookies()
public void shouldReturnResponseByMatchingPathAndMethodAndQueryStringParametersAndBodyParameters()
public void shouldReturnResponseByMatchingPathAndMethodAndQueryStringParametersAndBody()
public void shouldReturnResponseByMatchingPathAndMethodAndBodyParameters()
public void shouldReturnResponseByMatchingPathAndMethodAndParametersAndHeadersAndCookies()
public void shouldReturnResponseByNotMatchingBodyParameterWithNotOperatorForNameAndValue()
public void shouldReturnResponseByNotMatchingBodyParameterWithNotOperatorForName()
public void shouldReturnResponseByNotMatchingBodyParameterWithNotOperatorForValue()
public void shouldReturnResponseByNotMatchingQueryStringParameterWithNotOperatorForNameAndValue()
public void shouldReturnResponseByNotMatchingQueryStringParameterWithNotOperatorForName()
public void shouldReturnResponseByNotMatchingQueryStringParameterWithNotOperatorForValue()
public void shouldReturnResponseByNotMatchingCookieWithNotOperatorForNameAndValue()
public void shouldReturnResponseByNotMatchingCookieWithNotOperatorForName()
public void shouldReturnResponseByNotMatchingCookieWithNotOperatorForValue()
public void shouldReturnResponseByNotMatchingHeaderWithNotOperatorForNameAndValue()
public void shouldReturnResponseByNotMatchingHeaderWithNotOperatorForName()
public void shouldReturnResponseByNotMatchingHeaderWithNotOperatorForValue()
public void shouldNotReturnResponseForWhenTimeToLiveExpired()
public void shouldNotReturnResponseForNonMatchingBody()
public void shouldNotReturnResponseForMatchingBodyWithNotOperator()
public void shouldNotReturnResponseForNonMatchingXPathBody()
public void shouldNotReturnResponseForNonMatchingXmlBody()
public void shouldNotReturnResponseForNonMatchingJsonBody()
public void shouldNotReturnResponseForNonMatchingJsonBodyWithMatchType()
public void shouldNotReturnResponseForNonMatchingJsonSchema()
public void shouldNotReturnResponseForNonMatchingPath()
public void shouldNotReturnResponseForMatchingPathWithNotOperator()
public void shouldNotReturnResponseForMatchingMethodWithNotOperator()
public void shouldNotReturnResponseForNonMatchingBodyParameterName()
public void shouldNotReturnResponseForMatchingBodyParameterWithNotOperator()
public void shouldNotReturnResponseForNonMatchingBodyParameterValue()
public void shouldNotReturnResponseForNonMatchingQueryStringParameterName()
public void shouldNotReturnResponseForNonMatchingQueryStringParameterValue()
public void shouldNotReturnResponseForMatchingQueryStringParameterWithNotOperator()
public void shouldNotReturnResponseForNonMatchingCookieName()
public void shouldNotReturnResponseForNonMatchingCookieValue()
public void shouldNotReturnResponseForMatchingCookieWithNotOperator()
public void shouldNotReturnResponseForNonMatchingHeaderName()
public void shouldNotReturnResponseForNonMatchingHeaderValue()
public void shouldNotReturnResponseForMatchingHeaderWithNotOperator()
public void shouldVerifyReceivedRequests()
public void shouldVerifyReceivedRequestInSsl()
public void shouldVerifyReceivedRequestsWithRegexBody()
public void shouldVerifyReceivedRequestsWithNoBody()
public void shouldVerifyNotEnoughRequestsReceived()
public void shouldVerifyTooManyRequestsReceived()
public void shouldVerifyNoMatchingRequestsReceived()
public void shouldVerifyNoRequestsReceived()
public void shouldNotVerifyNoRequestsReceived()
public void shouldVerifyNoMatchingRequestsReceivedInSsl()
public void shouldVerifySequenceOfRequestsReceived()
public void shouldVerifySequenceOfRequestsReceivedIncludingThoseNotMatchingAnException()
public void shouldRetrieveSequenceOfRequestsReceivedIncludingThoseNotMatchingAnException()
public void shouldRetrieveSequenceOfExpectationsSetup()
public void shouldVerifySequenceOfRequestsNotReceived()
public void shouldClearExpectationsAndLogs()
public void shouldClearExpectationsOnly()
public void shouldClearLogsOnly()
public void shouldClearAllExpectationsWithNull()
public void shouldClearAllExpectationsWithEmptyRequest()
public void shouldClearExpectationsWithXPathBody()
public void shouldClearExpectationsWithJsonSchemaBody()
public void shouldClearExpectationsWithParameterBody()
public void shouldReset()
public void shouldEnsureThatInterruptedRequestsAreVerifiable() throws Exception
Exception
public void shouldEnsureThatRequestDelaysDoNotAffectOtherRequests() throws Exception
Exception
public void shouldReturnErrorForInvalidExpectation()
public void shouldReturnErrorForInvalidRequest()
protected void verifyRequestMatches(HttpRequest[] httpRequests, HttpRequest... httpRequestMatchers)
protected HttpResponse makeRequest(HttpRequest httpRequest)
protected HttpResponse makeRequest(HttpRequest httpRequest, Collection<String> headersToIgnore)
Copyright © 2018. All rights reserved.