From 62dbfa8e9ae6486833a9b03ff63ba330349ae48f Mon Sep 17 00:00:00 2001 From: Antoine Rey Date: Wed, 9 Oct 2024 22:41:48 +0200 Subject: [PATCH] Remove the unnecessary includeFilters --- .../samples/petclinic/service/ClinicServiceTests.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/test/java/org/springframework/samples/petclinic/service/ClinicServiceTests.java b/src/test/java/org/springframework/samples/petclinic/service/ClinicServiceTests.java index 2f3d00ce6ea..92a70c38c07 100644 --- a/src/test/java/org/springframework/samples/petclinic/service/ClinicServiceTests.java +++ b/src/test/java/org/springframework/samples/petclinic/service/ClinicServiceTests.java @@ -26,7 +26,6 @@ import org.springframework.boot.test.autoconfigure.jdbc.AutoConfigureTestDatabase; import org.springframework.boot.test.autoconfigure.jdbc.AutoConfigureTestDatabase.Replace; import org.springframework.boot.test.autoconfigure.orm.jpa.DataJpaTest; -import org.springframework.context.annotation.ComponentScan; import org.springframework.data.domain.Page; import org.springframework.data.domain.Pageable; import org.springframework.samples.petclinic.owner.Owner; @@ -36,7 +35,6 @@ import org.springframework.samples.petclinic.owner.Visit; import org.springframework.samples.petclinic.vet.Vet; import org.springframework.samples.petclinic.vet.VetRepository; -import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; /** @@ -67,7 +65,7 @@ * @author Michael Isvy * @author Dave Syer */ -@DataJpaTest(includeFilters = @ComponentScan.Filter(Service.class)) +@DataJpaTest // Ensure that if the mysql profile is active we connect to the real database: @AutoConfigureTestDatabase(replace = Replace.NONE) // @TestPropertySource("/application-postgres.properties")