Package org.springframework.security.test.context.support
package org.springframework.security.test.context.support
-
ClassDescriptionWhen used with
WithSecurityContextTestExecutionListenerthis annotation can be added to a test method to emulate running with a mocked user.An annotation to determine whatSecurityContextto use.WithSecurityContextFactory<A extends Annotation>An API that works with WithUserTestExcecutionListener for creating aSecurityContextthat is populated in theTestSecurityContextHolder.ATestExecutionListenerthat will find annotations that are annotated withWithSecurityContexton a test method or at the class level.When used withWithSecurityContextTestExecutionListenerthis annotation can be added to a test method to emulate running with aUserDetailsreturned from theUserDetailsService.