Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document order values for TestExecutionListener implementations #34265

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,12 @@ public class ApplicationEventsTestExecutionListener extends AbstractTestExecutio


/**
* Returns {@code 1800}.
* Returns {@code 1800}, which ensures that the {@code ApplicationEventsTestExecutionListener}
* is ordered after the
* {@link org.springframework.test.context.support.DirtiesContextBeforeModesTestExecutionListener
* DirtiesContextBeforeModesTestExecutionListener} and just before the
* {@link org.springframework.test.context.bean.override.BeanOverrideTestExecutionListener
* BeanOverrideTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,10 @@
public class EventPublishingTestExecutionListener extends AbstractTestExecutionListener {

/**
* Returns {@code 10000}.
* Returns {@code 10000}, which ensures that the {@code EventPublishingTestExecutionListener}
* is ordered after the
* {@link org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener
* SqlScriptsTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,12 @@ public class SqlScriptsTestExecutionListener extends AbstractTestExecutionListen


/**
* Returns {@code 5000}.
* Returns {@code 5000}, which ensures that the {@code SqlScriptsTestExecutionListener}
* is ordered after the
* {@link org.springframework.test.context.transaction.TransactionalTestExecutionListener
* TransactionalTestExecutionListener} and just before the
* {@link org.springframework.test.context.event.EventPublishingTestExecutionListener
* EventPublishingTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,12 @@ public MicrometerObservationRegistryTestExecutionListener() {


/**
* Returns {@code 2500}.
* Returns {@code 2500}, which ensures that the {@code MicrometerObservationRegistryTestExecutionListener}
* is ordered after the
* {@link org.springframework.test.context.support.DependencyInjectionTestExecutionListener
* DependencyInjectionTestExecutionListener} and just before the
* {@link org.springframework.test.context.support.DirtiesContextTestExecutionListener
* DirtiesContextTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,12 @@
public class CommonCachesTestExecutionListener extends AbstractTestExecutionListener {

/**
* Returns {@code 3005}.
* Returns {@code 3005}, which ensures that the {@code CommonCachesTestExecutionListener}
* is ordered after the
* {@link org.springframework.test.context.support.DirtiesContextTestExecutionListener
* DirtiesContextTestExecutionListener} and just before the
* {@link org.springframework.test.context.transaction.TransactionalTestExecutionListener
* TransactionalTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,12 @@ public class DependencyInjectionTestExecutionListener extends AbstractTestExecut


/**
* Returns {@code 2000}.
* Returns {@code 2000}, which ensures that the {@code ApplicationEventsTestExecutionListener}
* is ordered after the
* {@link org.springframework.test.context.bean.override.BeanOverrideTestExecutionListener
* BeanOverrideTestExecutionListener} and just before the
* {@link org.springframework.test.context.support.DirtiesContextTestExecutionListener
* DirtiesContextTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,12 @@
public class DirtiesContextBeforeModesTestExecutionListener extends AbstractDirtiesContextTestExecutionListener {

/**
* Returns {@code 1500}.
* Returns {@code 1500}, which ensures that the {@code DirtiesContextBeforeModesTestExecutionListener}
* is ordered after the
* {@link org.springframework.test.context.web.ServletTestExecutionListener
* ServletTestExecutionListener} and just before the
* {@link org.springframework.test.context.bean.override.BeanOverrideTestExecutionListener
* BeanOverrideTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,12 @@
public class DirtiesContextTestExecutionListener extends AbstractDirtiesContextTestExecutionListener {

/**
* Returns {@code 3000}.
* Returns {@code 3000}, which ensures that the {@code DirtiesContextTestExecutionListener}
* is ordered after the
* {@link org.springframework.test.context.support.DependencyInjectionTestExecutionListener
* DependencyInjectionTestExecutionListener} and just before the
* {@link org.springframework.test.context.support.CommonCachesTestExecutionListener
* CommonCachesTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,12 @@ public class TransactionalTestExecutionListener extends AbstractTestExecutionLis


/**
* Returns {@code 4000}.
* Returns {@code 4000}, which ensures that the {@code TransactionalTestExecutionListener}
* is ordered after the
* {@link org.springframework.test.context.support.CommonCachesTestExecutionListener
* CommonCachesTestExecutionListener} and just before the
* {@link org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener
* SqlScriptsTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,10 @@ public class ServletTestExecutionListener extends AbstractTestExecutionListener


/**
* Returns {@code 1000}.
* Returns {@code 1000}, which ensures that the {@code ServletTestExecutionListener}
* is ordered before the
* {@link org.springframework.test.context.support.DirtiesContextBeforeModesTestExecutionListener
* DirtiesContextBeforeModesTestExecutionListener}.
*/
@Override
public final int getOrder() {
Expand Down
Loading