|
1 | 1 | /*
|
2 |
| - * Copyright 2002-2015 the original author or authors. |
| 2 | + * Copyright 2002-2016 the original author or authors. |
3 | 3 | *
|
4 | 4 | * Licensed under the Apache License, Version 2.0 (the "License");
|
5 | 5 | * you may not use this file except in compliance with the License.
|
|
26 | 26 | import org.apache.commons.logging.LogFactory;
|
27 | 27 |
|
28 | 28 | import org.springframework.context.ApplicationContext;
|
29 |
| -import org.springframework.core.annotation.AnnotationUtils; |
| 29 | +import org.springframework.core.annotation.AnnotatedElementUtils; |
30 | 30 | import org.springframework.core.io.ByteArrayResource;
|
31 | 31 | import org.springframework.core.io.ClassPathResource;
|
32 | 32 | import org.springframework.core.io.Resource;
|
@@ -129,10 +129,10 @@ public void afterTestMethod(TestContext testContext) throws Exception {
|
129 | 129 | private void executeSqlScripts(TestContext testContext, ExecutionPhase executionPhase) throws Exception {
|
130 | 130 | boolean classLevel = false;
|
131 | 131 |
|
132 |
| - Set<Sql> sqlAnnotations = AnnotationUtils.getRepeatableAnnotations(testContext.getTestMethod(), Sql.class, |
| 132 | + Set<Sql> sqlAnnotations = AnnotatedElementUtils.getMergedRepeatableAnnotations(testContext.getTestMethod(), Sql.class, |
133 | 133 | SqlGroup.class);
|
134 | 134 | if (sqlAnnotations.isEmpty()) {
|
135 |
| - sqlAnnotations = AnnotationUtils.getRepeatableAnnotations(testContext.getTestClass(), Sql.class, |
| 135 | + sqlAnnotations = AnnotatedElementUtils.getMergedRepeatableAnnotations(testContext.getTestClass(), Sql.class, |
136 | 136 | SqlGroup.class);
|
137 | 137 | if (!sqlAnnotations.isEmpty()) {
|
138 | 138 | classLevel = true;
|
|
0 commit comments