Interface WithSecurityContextFactory<A extends java.lang.annotation.Annotation>
-
- Type Parameters:
A-
public interface WithSecurityContextFactory<A extends java.lang.annotation.Annotation>An API that works with WithUserTestExcecutionListener for creating aSecurityContextthat is populated in theTestSecurityContextHolder.- Since:
- 4.0
- See Also:
WithSecurityContext,WithMockUser,WithUserDetails
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.springframework.security.core.context.SecurityContextcreateSecurityContext(A annotation)Create aSecurityContextgiven an Annotation.
-
-
-
Method Detail
-
createSecurityContext
org.springframework.security.core.context.SecurityContext createSecurityContext(A annotation)
Create aSecurityContextgiven an Annotation.- Parameters:
annotation- theAnnotationto create theSecurityContextfrom. Cannot be null.- Returns:
- the
SecurityContextto use. Cannot be null.
-
-