Annotation Interface AutoConfigureRestDocs
@Target(TYPE)
@Retention(RUNTIME)
@Documented
@Inherited
@ImportAutoConfiguration
@Import(org.springframework.boot.test.autoconfigure.restdocs.RestDocumentationContextProviderRegistrar.class)
@PropertyMapping("spring.test.restdocs")
public @interface AutoConfigureRestDocs
Annotation that can be applied to a test class to enable and configure
 auto-configuration of Spring REST Docs. The auto-configuration sets up
 
MockMvc-based testing of a servlet web application, WebTestClient-based
 testing of a reactive web application, or RestAssured-based testing of any web
 application over HTTP.
 
 Allows configuration of the output directory and the host, scheme, and port of
 generated URIs. When further configuration is required a
 RestDocsMockMvcConfigurationCustomizer,
 RestDocsWebTestClientConfigurationCustomizer, or
 RestDocsRestAssuredConfigurationCustomizer bean can be used.
- Since:
- 1.4.0
- Author:
- Andy Wilkinson
- See Also:
- 
Optional Element SummaryOptional ElementsModifier and TypeOptional ElementDescriptionThe output directory to which generated snippets will be written.The host to be used in documented URIs.intThe port to be used in documented URIs.The scheme (typicallyhttporhttps) to be used in documented URIs.The output directory to which generated snippets will be written.
- 
Element Details- 
valueThe output directory to which generated snippets will be written. An alias foroutputDir().- Returns:
- the output directory
 - Default:
- ""
 
- 
outputDirThe output directory to which generated snippets will be written. An alias forvalue().- Returns:
- the output directory
 - Default:
- ""
 
- 
uriSchemeString uriSchemeThe scheme (typicallyhttporhttps) to be used in documented URIs. Defaults tohttp.- Returns:
- the scheme
 - Default:
- "http"
 
- 
uriHostString uriHostThe host to be used in documented URIs. Defaults tolocalhost.- Returns:
- the host
 - Default:
- "localhost"
 
- 
uriPortint uriPortThe port to be used in documented URIs. Defaults to8080.- Returns:
- the port
 - Default:
- 8080
 
 
-