gh-6899: @WithMockUser as metaannotation

This commit is contained in:
mariusz
2022-09-01 22:17:48 +02:00
committed by Rob Winch
parent 86fbb8db07
commit b478e5bc93
2 changed files with 26 additions and 1 deletions

View File

@@ -148,7 +148,7 @@ public class WithSecurityContextTestExecutionListener extends AbstractTestExecut
}
private Annotation findAnnotation(AnnotatedElement annotated, Class<? extends Annotation> type) {
Annotation findAnnotation = AnnotationUtils.findAnnotation(annotated, type);
Annotation findAnnotation = AnnotatedElementUtils.findMergedAnnotation(annotated, type);
if (findAnnotation != null) {
return findAnnotation;
}