Spring Boot Testing & @DirtiesContext

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Spring Boot Testing & @DirtiesContext

James Green
I have an itch to scratch. Why does my test class require @DirtiesContext
to avoid a stack trace telling me that ActiveMQ was never started and so it
cannot be stopped after my test completes?


@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_EACH_TEST_METHOD)
public class FooTest {