Class DirtiesContexttestExecutionListener

All Implemented Interfaces:
Ordered, testExecutionListener

public class DirtiesContexttestExecutionListener extends AbstractDirtiesContexttestExecutionListener
testExecutionListener which provides support for marking the ApplicationContext associated with a test as dirty for both test classes and test methods annotated with the @DirtiesContext annotation.

This listener supports test methods with the method mode set to AFTER_METHOD and test classes with the class mode set to AFTER_EACH_test_METHOD or AFTER_CLASS. For support for BEFORE modes, see DirtiesContextBeforeModestestExecutionListener.

When merging testExecutionListeners with the defaults, this listener will automatically be ordered after the DependencyInjectiontestExecutionListener; otherwise, this listener must be manually configured to execute after the DependencyInjectiontestExecutionListener.

Since:
2.5
Author:
Sam Brannen
See Also: