Skip to content

Commit 1f537b9

Browse files
committed
Demonstrate how to disable Bean Override tests in AOT mode
See gh-29122
1 parent cade3c7 commit 1f537b9

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

spring-test/src/test/java/org/springframework/test/context/aot/AotIntegrationTests.java

+4
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,8 @@ void endToEndTestsForEntireSpringTestModule() {
137137
.filter(clazz -> clazz.getSimpleName().endsWith("Tests"))
138138
// TestNG EJB tests use @PersistenceContext which is not yet supported in tests in AOT mode.
139139
.filter(clazz -> !clazz.getPackageName().contains("testng.transaction.ejb"))
140+
// Uncomment the following to disable Bean Override tests since they are not yet supported in AOT mode.
141+
// .filter(clazz -> !clazz.getPackageName().contains("test.context.bean.override"))
140142
.toList();
141143

142144
// Optionally set failOnError flag to true to halt processing at the first failure.
@@ -147,6 +149,8 @@ void endToEndTestsForEntireSpringTestModule() {
147149
@Test
148150
void endToEndTestsForSelectedTestClasses() {
149151
List<Class<?>> testClasses = List.of(
152+
org.springframework.test.context.bean.override.convention.TestBeanIntegrationTests.class,
153+
org.springframework.test.context.bean.override.mockito.MockitoBeanIntegrationTests.class,
150154
org.springframework.test.context.junit4.SpringJUnit4ClassRunnerAppCtxTests.class,
151155
org.springframework.test.context.junit4.ParameterizedDependencyInjectionTests.class
152156
);

0 commit comments

Comments
 (0)