From 75bf430eb17c179eb7705841cea1823a7f7e5e41 Mon Sep 17 00:00:00 2001 From: Phillip Webb Date: Mon, 8 Nov 2021 13:12:23 -0800 Subject: [PATCH] Polish ImportsContextCustomizerTests Update the test classes to include an `@Import` annotation. Without this the tests would not fail even if the filter is missing. --- .../boot/test/context/ImportsContextCustomizerTests.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/spring-boot-project/spring-boot-test/src/test/java/org/springframework/boot/test/context/ImportsContextCustomizerTests.java b/spring-boot-project/spring-boot-test/src/test/java/org/springframework/boot/test/context/ImportsContextCustomizerTests.java index 6ed9f8419f..4f8239bc33 100644 --- a/spring-boot-project/spring-boot-test/src/test/java/org/springframework/boot/test/context/ImportsContextCustomizerTests.java +++ b/spring-boot-project/spring-boot-test/src/test/java/org/springframework/boot/test/context/ImportsContextCustomizerTests.java @@ -105,31 +105,37 @@ class ImportsContextCustomizerTests { } @Metadata(d2 = "foo") + @Import(TestImportSelector.class) static class FirstKotlinAnnotatedTestClass { } @Metadata(d2 = "bar") + @Import(TestImportSelector.class) static class SecondKotlinAnnotatedTestClass { } @SpecMetadata(filename = "foo", line = 10) + @Import(TestImportSelector.class) static class FirstSpockFrameworkAnnotatedTestClass { } @SpecMetadata(filename = "bar", line = 10) + @Import(TestImportSelector.class) static class SecondSpockFrameworkAnnotatedTestClass { } @Stepwise + @Import(TestImportSelector.class) static class FirstSpockLangAnnotatedTestClass { } @Issue("1234") + @Import(TestImportSelector.class) static class SecondSpockLangAnnotatedTestClass { }