Skip to content

Commit 0adec6d

Browse files
committed
Apply @⁠DisabledInAotMode to remaining @⁠ContextHierarchy integration tests
See gh-29122
1 parent bb95f2e commit 0adec6d

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

Diff for: spring-test/src/test/java/org/springframework/test/context/hierarchies/meta/MetaHierarchyLevelTwoTests.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2019 the original author or authors.
2+
* Copyright 2002-2023 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -25,6 +25,7 @@
2525
import org.springframework.context.annotation.Profile;
2626
import org.springframework.test.context.ActiveProfiles;
2727
import org.springframework.test.context.ContextConfiguration;
28+
import org.springframework.test.context.aot.DisabledInAotMode;
2829

2930
import static org.assertj.core.api.Assertions.assertThat;
3031

@@ -34,6 +35,7 @@
3435
*/
3536
@ContextConfiguration
3637
@ActiveProfiles("prod")
38+
@DisabledInAotMode // @ContextHierarchy is not supported in AOT.
3739
class MetaHierarchyLevelTwoTests extends MetaHierarchyLevelOneTests {
3840

3941
@Configuration

Diff for: spring-test/src/test/java/org/springframework/test/context/hierarchies/standard/TestHierarchyLevelTwoWithBareContextConfigurationInSubclassTests.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2019 the original author or authors.
2+
* Copyright 2002-2023 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -24,6 +24,7 @@
2424
import org.springframework.context.annotation.Bean;
2525
import org.springframework.context.annotation.Configuration;
2626
import org.springframework.test.context.ContextConfiguration;
27+
import org.springframework.test.context.aot.DisabledInAotMode;
2728
import org.springframework.test.context.junit.jupiter.SpringExtension;
2829

2930
import static org.assertj.core.api.Assertions.assertThat;
@@ -34,6 +35,7 @@
3435
*/
3536
@ExtendWith(SpringExtension.class)
3637
@ContextConfiguration
38+
@DisabledInAotMode // @ContextHierarchy is not supported in AOT.
3739
class TestHierarchyLevelTwoWithBareContextConfigurationInSubclassTests extends
3840
TestHierarchyLevelOneWithBareContextConfigurationInSubclassTests {
3941

0 commit comments

Comments
 (0)