diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Cat.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Cat.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Cat.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Cat.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterApp.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterApp.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterApp.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterApp.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Elephant.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Elephant.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Elephant.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Elephant.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Loin.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Lion.java similarity index 72% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Loin.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Lion.java index 6bfdfeb321..030acc2976 100644 --- a/spring-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Loin.java +++ b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/aspectj/Lion.java @@ -1,4 +1,4 @@ package com.baeldung.componentscan.filter.aspectj; -public class Loin { +public class Lion { } diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/assignable/Animal.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/assignable/Animal.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/assignable/Animal.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/assignable/Animal.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/assignable/Cat.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/assignable/Cat.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/assignable/Cat.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/assignable/Cat.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterApp.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterApp.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterApp.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterApp.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/assignable/Elephant.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/assignable/Elephant.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/assignable/Elephant.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/assignable/Elephant.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/custom/Cat.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/Cat.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/custom/Cat.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/Cat.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilter.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilter.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilter.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilter.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterApp.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterApp.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterApp.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterApp.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/custom/Elephant.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/Elephant.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/custom/Elephant.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/Elephant.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/custom/Loin.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/Lion.java similarity index 72% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/custom/Loin.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/Lion.java index 5deb4af9f3..9f4228442d 100644 --- a/spring-di/src/main/java/com/baeldung/componentscan/filter/custom/Loin.java +++ b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/custom/Lion.java @@ -1,4 +1,4 @@ package com.baeldung.componentscan.filter.custom; -public class Loin { +public class Lion { } diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/regex/Cat.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/regex/Cat.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/regex/Cat.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/regex/Cat.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterApp.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterApp.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterApp.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterApp.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/regex/Elephant.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/regex/Elephant.java similarity index 100% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/regex/Elephant.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/regex/Elephant.java diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/regex/Loin.java b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/regex/Lion.java similarity index 72% rename from spring-di/src/main/java/com/baeldung/componentscan/filter/regex/Loin.java rename to spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/regex/Lion.java index 5b7949be38..56d233d92f 100644 --- a/spring-di/src/main/java/com/baeldung/componentscan/filter/regex/Loin.java +++ b/spring-boot-modules/spring-boot-di/src/main/java/com/baeldung/componentscan/filter/regex/Lion.java @@ -1,4 +1,4 @@ package com.baeldung.componentscan.filter.regex; -public class Loin { +public class Lion { } diff --git a/spring-di/src/test/java/com/baeldung/componentscan/filter/annotation/ComponentScanAnnotationFilterAppIntegrationTest.java b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/annotation/ComponentScanAnnotationFilterAppIntegrationTest.java similarity index 95% rename from spring-di/src/test/java/com/baeldung/componentscan/filter/annotation/ComponentScanAnnotationFilterAppIntegrationTest.java rename to spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/annotation/ComponentScanAnnotationFilterAppIntegrationTest.java index 9eb0b67c21..33667e78e4 100644 --- a/spring-di/src/test/java/com/baeldung/componentscan/filter/annotation/ComponentScanAnnotationFilterAppIntegrationTest.java +++ b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/annotation/ComponentScanAnnotationFilterAppIntegrationTest.java @@ -1,6 +1,5 @@ package com.baeldung.componentscan.filter.annotation; -import static org.junit.Assert.assertThat; import java.util.Arrays; import java.util.List; @@ -13,6 +12,7 @@ import org.springframework.context.ApplicationContext; import org.springframework.context.annotation.AnnotationConfigApplicationContext; import org.springframework.test.context.junit4.SpringRunner; import static org.hamcrest.CoreMatchers.*; +import static org.hamcrest.MatcherAssert.assertThat; @RunWith(SpringRunner.class) @SpringBootTest(classes = ComponentScanAnnotationFilterApp.class) diff --git a/spring-di/src/test/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterAppUnitTest.java b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterAppUnitTest.java similarity index 95% rename from spring-di/src/test/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterAppUnitTest.java rename to spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterAppUnitTest.java index a85c451299..11283eb177 100644 --- a/spring-di/src/test/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterAppUnitTest.java +++ b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/aspectj/ComponentScanAspectJFilterAppUnitTest.java @@ -1,6 +1,5 @@ package com.baeldung.componentscan.filter.aspectj; -import static org.junit.Assert.assertThat; import java.util.Arrays; import java.util.List; @@ -13,6 +12,7 @@ import org.springframework.context.ApplicationContext; import org.springframework.context.annotation.AnnotationConfigApplicationContext; import org.springframework.test.context.junit4.SpringRunner; import static org.hamcrest.CoreMatchers.*; +import static org.hamcrest.MatcherAssert.assertThat; @RunWith(SpringRunner.class) @SpringBootTest(classes = ComponentScanAspectJFilterApp.class) diff --git a/spring-di/src/test/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterAppIntegrationTest.java b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterAppIntegrationTest.java similarity index 96% rename from spring-di/src/test/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterAppIntegrationTest.java rename to spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterAppIntegrationTest.java index edd82f435c..98d553d960 100644 --- a/spring-di/src/test/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterAppIntegrationTest.java +++ b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/assignable/ComponentScanAssignableTypeFilterAppIntegrationTest.java @@ -1,6 +1,5 @@ package com.baeldung.componentscan.filter.assignable; -import static org.junit.Assert.assertThat; import java.util.Arrays; import java.util.List; @@ -13,6 +12,7 @@ import org.springframework.context.ApplicationContext; import org.springframework.context.annotation.AnnotationConfigApplicationContext; import org.springframework.test.context.junit4.SpringRunner; import static org.hamcrest.CoreMatchers.*; +import static org.hamcrest.MatcherAssert.assertThat; @RunWith(SpringRunner.class) @SpringBootTest(classes = ComponentScanAssignableTypeFilterApp.class) diff --git a/spring-di/src/test/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterAppIntegrationTest.java b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterAppIntegrationTest.java similarity index 96% rename from spring-di/src/test/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterAppIntegrationTest.java rename to spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterAppIntegrationTest.java index 9902a620ad..7047bc5ec9 100644 --- a/spring-di/src/test/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterAppIntegrationTest.java +++ b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/custom/ComponentScanCustomFilterAppIntegrationTest.java @@ -12,7 +12,7 @@ import java.util.List; import java.util.stream.Collectors; import static org.hamcrest.CoreMatchers.*; -import static org.junit.Assert.assertThat; +import static org.hamcrest.MatcherAssert.assertThat; @RunWith(SpringRunner.class) @SpringBootTest(classes = ComponentScanCustomFilterApp.class) diff --git a/spring-di/src/test/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterAppIntegrationTest.java b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterAppIntegrationTest.java similarity index 95% rename from spring-di/src/test/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterAppIntegrationTest.java rename to spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterAppIntegrationTest.java index 38d6acd7f8..83d05314af 100644 --- a/spring-di/src/test/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterAppIntegrationTest.java +++ b/spring-boot-modules/spring-boot-di/src/test/java/com/baeldung/componentscan/filter/regex/ComponentScanRegexFilterAppIntegrationTest.java @@ -1,6 +1,5 @@ package com.baeldung.componentscan.filter.regex; -import static org.junit.Assert.assertThat; import java.util.Arrays; import java.util.List; @@ -13,6 +12,7 @@ import org.springframework.context.ApplicationContext; import org.springframework.context.annotation.AnnotationConfigApplicationContext; import org.springframework.test.context.junit4.SpringRunner; import static org.hamcrest.CoreMatchers.*; +import static org.hamcrest.MatcherAssert.assertThat; @RunWith(SpringRunner.class) @SpringBootTest(classes = ComponentScanRegexFilterApp.class) diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/annotation/Animal.java b/spring-di/src/main/java/com/baeldung/componentscan/filter/annotation/Animal.java deleted file mode 100644 index 7ec076abc7..0000000000 --- a/spring-di/src/main/java/com/baeldung/componentscan/filter/annotation/Animal.java +++ /dev/null @@ -1,11 +0,0 @@ -package com.baeldung.componentscan.filter.annotation; - -import java.lang.annotation.ElementType; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -@Retention(RetentionPolicy.RUNTIME) -@Target(ElementType.TYPE) -public @interface Animal { -} diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/annotation/ComponentScanAnnotationFilterApp.java b/spring-di/src/main/java/com/baeldung/componentscan/filter/annotation/ComponentScanAnnotationFilterApp.java deleted file mode 100644 index 7849e4e10a..0000000000 --- a/spring-di/src/main/java/com/baeldung/componentscan/filter/annotation/ComponentScanAnnotationFilterApp.java +++ /dev/null @@ -1,13 +0,0 @@ -package com.baeldung.componentscan.filter.annotation; - -import org.springframework.context.annotation.ComponentScan; -import org.springframework.context.annotation.Configuration; -import org.springframework.context.annotation.FilterType; - -@Configuration -@ComponentScan(includeFilters = @ComponentScan.Filter(type = FilterType.ANNOTATION, classes = Animal.class)) -public class ComponentScanAnnotationFilterApp { - - public static void main(String[] args) { - } -} diff --git a/spring-di/src/main/java/com/baeldung/componentscan/filter/annotation/Elephant.java b/spring-di/src/main/java/com/baeldung/componentscan/filter/annotation/Elephant.java deleted file mode 100644 index 758775a737..0000000000 --- a/spring-di/src/main/java/com/baeldung/componentscan/filter/annotation/Elephant.java +++ /dev/null @@ -1,5 +0,0 @@ -package com.baeldung.componentscan.filter.annotation; - -@Animal -public class Elephant { -}