List of usage examples for org.springframework.restdocs.operation.preprocess Preprocessors modifyUris
public static UriModifyingOperationPreprocessor modifyUris()
From source file:com.netflix.genie.web.controllers.RestControllerIntegrationTestBase.java
/** * Clean out the db before every test.//from w w w. j av a 2s.c o m * * @throws Exception on error */ public void setup() throws Exception { this.jobRepository.deleteAll(); this.clusterRepository.deleteAll(); this.commandRepository.deleteAll(); this.applicationRepository.deleteAll(); this.fileRepository.deleteAll(); this.tagRepository.deleteAll(); this.requestSpecification = new RequestSpecBuilder() .addFilter(RestAssuredRestDocumentation.documentationConfiguration(this.restDocumentation) .snippets().withAdditionalDefaults(new WireMockSnippet()).and().operationPreprocessors() .withRequestDefaults(Preprocessors.prettyPrint(), Preprocessors.modifyUris().scheme(URI_SCHEME).host(URI_HOST).removePort()) .withResponseDefaults(Preprocessors.prettyPrint(), Preprocessors.modifyUris().host(URI_HOST).scheme(URI_SCHEME).removePort())) .build(); }