Package org.springframework.security.test.context.support
-
Interface Summary Interface Description WithSecurityContextFactory<A extends java.lang.annotation.Annotation> An API that works with WithUserTestExcecutionListener for creating aSecurityContextthat is populated in theTestSecurityContextHolder. -
Class Summary Class Description ReactorContextTestExecutionListener Sets up the Reactor Context with the Authentication from the TestSecurityContextHolder and then clears the Reactor Context at the end of the tests.WithSecurityContextTestExecutionListener ATestExecutionListenerthat will find annotations that are annotated withWithSecurityContexton a test method or at the class level. -
Enum Summary Enum Description TestExecutionEvent Represents the events on the methods ofTestExecutionListener -
Annotation Types Summary Annotation Type Description WithAnonymousUser When used withWithSecurityContextTestExecutionListenerthis annotation can be added to a test method to emulate running with an anonymous user.WithMockUser When used withWithSecurityContextTestExecutionListenerthis annotation can be added to a test method to emulate running with a mocked user.WithSecurityContext An annotation to determine whatSecurityContextto use.WithUserDetails When used withWithSecurityContextTestExecutionListenerthis annotation can be added to a test method to emulate running with aUserDetailsreturned from theUserDetailsService.