Discover @DynamicPropertySource methods on enclosing test classes

gh-19930 introduced support for finding class-level test configuration
annotations on enclosing classes when using JUnit Jupiter @Nested test
classes, but support for @DynamicPropertySource methods got overlooked
since they are method-level annotations.

This commit addresses this shortcoming by introducing full support for
@NestedTestConfiguration semantics for @DynamicPropertySource methods
on enclosing classes.

Closes gh-26091
This commit is contained in:
Sam Brannen
2020-11-15 20:59:15 +01:00
parent 0b580d194d
commit 0819a9fcc9
5 changed files with 204 additions and 1 deletions

View File

@@ -1877,6 +1877,7 @@ following annotations.
* <<spring-testing-annotation-contexthierarchy>>
* <<spring-testing-annotation-activeprofiles>>
* <<spring-testing-annotation-testpropertysource>>
* <<spring-testing-annotation-dynamicpropertysource>>
* <<spring-testing-annotation-dirtiescontext>>
* <<spring-testing-annotation-testexecutionlisteners>>
* <<testcontext-tx,`@Transactional`>>