You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Beginning with Java 16, inner classes may contain static members. We
therefore need to search for @DynamicPropertySource methods in the
current class after searching enclosing classes so that a local
@DynamicPropertySource method can override properties registered in an
enclosing class.
However, since Spring Framework 5.3.x is built using Java 8, this
commit removes DynamicPropertySourceOverridesEnclosingClassTests since
it declares a static method in a @nested (inner) test class, which
results in a compiler error on Java 8.
See https://bugs.openjdk.org/browse/JDK-8254321
See gh-31085
Copy file name to clipboardExpand all lines: spring-test/src/main/java/org/springframework/test/context/support/DynamicPropertiesContextCustomizerFactory.java
+6-1Lines changed: 6 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
/*
2
-
* Copyright 2002-2020 the original author or authors.
2
+
* Copyright 2002-2023 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.
@@ -55,6 +55,11 @@ public DynamicPropertiesContextCustomizer createContextCustomizer(Class<?> testC
Copy file name to clipboardExpand all lines: spring-test/src/test/java/org/springframework/test/context/junit/jupiter/nested/DynamicPropertySourceNestedTests.java
-17Lines changed: 0 additions & 17 deletions
Original file line number
Diff line number
Diff line change
@@ -39,7 +39,6 @@
39
39
* {@link SpringExtension} in a JUnit Jupiter environment.
40
40
*
41
41
* @author Sam Brannen
42
-
* @author Yanming Zhou
43
42
* @since 5.3.2
44
43
*/
45
44
@SpringJUnitConfig
@@ -126,22 +125,6 @@ void serviceHasInjectedValues(@Autowired Service service) {
0 commit comments