Skip to content

Commit c2dd666

Browse files
committed
Revise method signature in TestRuntimeHintsRegistrar
1 parent 16ff05e commit c2dd666

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

spring-test/src/main/java/org/springframework/test/context/aot/TestContextAotGenerator.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,8 +120,8 @@ private void processAheadOfTime(MultiValueMap<MergedContextConfiguration, Class<
120120
logger.debug(LogMessage.format("Generating AOT artifacts for test classes %s",
121121
testClasses.stream().map(Class::getName).toList()));
122122
try {
123-
this.testRuntimeHintsRegistrars.forEach(registrar -> registrar.registerHints(this.runtimeHints,
124-
mergedConfig, Collections.unmodifiableList(testClasses), getClass().getClassLoader()));
123+
this.testRuntimeHintsRegistrars.forEach(registrar -> registrar.registerHints(mergedConfig,
124+
Collections.unmodifiableList(testClasses), this.runtimeHints, getClass().getClassLoader()));
125125

126126
// Use first test class discovered for a given unique MergedContextConfiguration.
127127
Class<?> testClass = testClasses.get(0);

spring-test/src/main/java/org/springframework/test/context/aot/TestRuntimeHintsRegistrar.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,13 +45,13 @@ public interface TestRuntimeHintsRegistrar {
4545

4646
/**
4747
* Contribute hints to the given {@link RuntimeHints} instance.
48-
* @param runtimeHints the {@code RuntimeHints} to use
4948
* @param mergedConfig the merged context configuration to process
5049
* @param testClasses the test classes that share the supplied merged context
5150
* configuration
51+
* @param runtimeHints the {@code RuntimeHints} to use
5252
* @param classLoader the classloader to use
5353
*/
54-
void registerHints(RuntimeHints runtimeHints, MergedContextConfiguration mergedConfig,
55-
List<Class<?>> testClasses, ClassLoader classLoader);
54+
void registerHints(MergedContextConfiguration mergedConfig, List<Class<?>> testClasses,
55+
RuntimeHints runtimeHints, ClassLoader classLoader);
5656

5757
}

spring-test/src/main/java/org/springframework/test/context/aot/hint/StandardTestRuntimeHints.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ class StandardTestRuntimeHints implements TestRuntimeHintsRegistrar {
4747

4848

4949
@Override
50-
public void registerHints(RuntimeHints runtimeHints, MergedContextConfiguration mergedConfig,
51-
List<Class<?>> testClasses, ClassLoader classLoader) {
50+
public void registerHints(MergedContextConfiguration mergedConfig, List<Class<?>> testClasses,
51+
RuntimeHints runtimeHints, ClassLoader classLoader) {
5252

5353
registerHintsForMergedContextConfiguration(runtimeHints, mergedConfig);
5454
testClasses.forEach(testClass -> registerHintsForActiveProfilesResolvers(runtimeHints, testClass));

0 commit comments

Comments
 (0)