Annotation that can be used in combination with
for a typical JPA test. Can be used when a test focuses only
Using this annotation will disable full auto-configuration and instead apply only
configuration relevant to JPA tests.
By default, tests annotated with
@DataJpaTest will use an embedded in-memory
database (replacing any explicit or usually auto-configured DataSource). The
@AutoConfigureTestDatabase annotation can be used to
override these settings.
If you are looking to load your full application configuration, but use an embedded
database, you should consider
@SpringBootTest combined with
@AutoConfigureTestDatabase rather than this