Register runtime hints for @TestExecutionListeners

Closes gh-29024
This commit is contained in:
Sam Brannen
2022-09-02 14:52:58 +02:00
parent 34635d7751
commit cced3cba09
3 changed files with 16 additions and 2 deletions

View File

@@ -199,6 +199,9 @@ public class TestContextAotGenerator {
TestContextBootstrapper testContextBootstrapper =
BootstrapUtils.resolveTestContextBootstrapper(testClass);
registerDeclaredConstructors(testContextBootstrapper.getClass());
testContextBootstrapper.getTestExecutionListeners().stream()
.map(Object::getClass)
.forEach(this::registerDeclaredConstructors);
return testContextBootstrapper.buildMergedContextConfiguration();
}