Requalify tests as LONG_RUNNING
Prior to this commit, some tests would belong to the PERFORMANCE `TestGroup`, while they were not testing for performance but rather performing functional tests that involve long running operations or timeouts. This commit moves those tests to the LONG_RUNNING `TestGroup`. See gh-24830
This commit is contained in:
parent
f89bd47188
commit
e02d3f32b4
|
@ -40,7 +40,7 @@ import org.springframework.transaction.testfixture.CallCountingTransactionManage
|
||||||
import static org.assertj.core.api.Assertions.assertThat;
|
import static org.assertj.core.api.Assertions.assertThat;
|
||||||
import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
|
import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
|
||||||
import static org.mockito.Mockito.mock;
|
import static org.mockito.Mockito.mock;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Integration tests cornering bug SPR-8651, which revealed that @Scheduled methods may
|
* Integration tests cornering bug SPR-8651, which revealed that @Scheduled methods may
|
||||||
|
@ -52,7 +52,7 @@ import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
||||||
* @since 3.1
|
* @since 3.1
|
||||||
*/
|
*/
|
||||||
@SuppressWarnings("resource")
|
@SuppressWarnings("resource")
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
class ScheduledAndTransactionalAnnotationIntegrationTests {
|
class ScheduledAndTransactionalAnnotationIntegrationTests {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -21,7 +21,7 @@ import org.junit.jupiter.api.Test;
|
||||||
import org.springframework.core.testfixture.EnabledForTestGroups;
|
import org.springframework.core.testfixture.EnabledForTestGroups;
|
||||||
|
|
||||||
import static org.assertj.core.api.Assertions.assertThat;
|
import static org.assertj.core.api.Assertions.assertThat;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Rob Harrop
|
* @author Rob Harrop
|
||||||
|
@ -77,7 +77,7 @@ public class RefreshableTargetSourceTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void testRefreshOverTime() throws Exception {
|
public void testRefreshOverTime() throws Exception {
|
||||||
CountingRefreshableTargetSource ts = new CountingRefreshableTargetSource(true);
|
CountingRefreshableTargetSource ts = new CountingRefreshableTargetSource(true);
|
||||||
ts.setRefreshCheckDelay(100);
|
ts.setRefreshCheckDelay(100);
|
||||||
|
|
|
@ -38,7 +38,7 @@ import org.springframework.util.ReflectionUtils;
|
||||||
import org.springframework.util.concurrent.ListenableFuture;
|
import org.springframework.util.concurrent.ListenableFuture;
|
||||||
|
|
||||||
import static org.assertj.core.api.Assertions.assertThat;
|
import static org.assertj.core.api.Assertions.assertThat;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Unit tests for {@link AnnotationAsyncExecutionAspect}.
|
* Unit tests for {@link AnnotationAsyncExecutionAspect}.
|
||||||
|
@ -46,7 +46,7 @@ import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
||||||
* @author Ramnivas Laddad
|
* @author Ramnivas Laddad
|
||||||
* @author Stephane Nicoll
|
* @author Stephane Nicoll
|
||||||
*/
|
*/
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public class AnnotationAsyncExecutionAspectTests {
|
public class AnnotationAsyncExecutionAspectTests {
|
||||||
|
|
||||||
private static final long WAIT_TIME = 1000; //milliseconds
|
private static final long WAIT_TIME = 1000; //milliseconds
|
||||||
|
|
|
@ -46,7 +46,7 @@ import static org.assertj.core.api.Assertions.assertThatIllegalArgumentException
|
||||||
import static org.mockito.BDDMockito.given;
|
import static org.mockito.BDDMockito.given;
|
||||||
import static org.mockito.Mockito.mock;
|
import static org.mockito.Mockito.mock;
|
||||||
import static org.mockito.Mockito.verify;
|
import static org.mockito.Mockito.verify;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
|
@ -96,7 +96,7 @@ public class QuartzSupportTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void schedulerWithTaskExecutor() throws Exception {
|
public void schedulerWithTaskExecutor() throws Exception {
|
||||||
CountingTaskExecutor taskExecutor = new CountingTaskExecutor();
|
CountingTaskExecutor taskExecutor = new CountingTaskExecutor();
|
||||||
DummyJob.count = 0;
|
DummyJob.count = 0;
|
||||||
|
@ -137,7 +137,7 @@ public class QuartzSupportTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void schedulerWithQuartzJobBean() throws Exception {
|
public void schedulerWithQuartzJobBean() throws Exception {
|
||||||
DummyJob.param = 0;
|
DummyJob.param = 0;
|
||||||
DummyJob.count = 0;
|
DummyJob.count = 0;
|
||||||
|
@ -170,7 +170,7 @@ public class QuartzSupportTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void schedulerWithSpringBeanJobFactory() throws Exception {
|
public void schedulerWithSpringBeanJobFactory() throws Exception {
|
||||||
DummyJob.param = 0;
|
DummyJob.param = 0;
|
||||||
DummyJob.count = 0;
|
DummyJob.count = 0;
|
||||||
|
@ -205,7 +205,7 @@ public class QuartzSupportTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void schedulerWithSpringBeanJobFactoryAndParamMismatchNotIgnored() throws Exception {
|
public void schedulerWithSpringBeanJobFactoryAndParamMismatchNotIgnored() throws Exception {
|
||||||
DummyJob.param = 0;
|
DummyJob.param = 0;
|
||||||
DummyJob.count = 0;
|
DummyJob.count = 0;
|
||||||
|
@ -241,7 +241,7 @@ public class QuartzSupportTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void schedulerWithSpringBeanJobFactoryAndQuartzJobBean() throws Exception {
|
public void schedulerWithSpringBeanJobFactoryAndQuartzJobBean() throws Exception {
|
||||||
DummyJobBean.param = 0;
|
DummyJobBean.param = 0;
|
||||||
DummyJobBean.count = 0;
|
DummyJobBean.count = 0;
|
||||||
|
@ -275,7 +275,7 @@ public class QuartzSupportTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void schedulerWithSpringBeanJobFactoryAndJobSchedulingData() throws Exception {
|
public void schedulerWithSpringBeanJobFactoryAndJobSchedulingData() throws Exception {
|
||||||
DummyJob.param = 0;
|
DummyJob.param = 0;
|
||||||
DummyJob.count = 0;
|
DummyJob.count = 0;
|
||||||
|
@ -316,7 +316,7 @@ public class QuartzSupportTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void twoAnonymousMethodInvokingJobDetailFactoryBeans() throws Exception {
|
public void twoAnonymousMethodInvokingJobDetailFactoryBeans() throws Exception {
|
||||||
Thread.sleep(3000);
|
Thread.sleep(3000);
|
||||||
try (ClassPathXmlApplicationContext ctx = context("multipleAnonymousMethodInvokingJobDetailFB.xml")) {
|
try (ClassPathXmlApplicationContext ctx = context("multipleAnonymousMethodInvokingJobDetailFB.xml")) {
|
||||||
|
@ -331,7 +331,7 @@ public class QuartzSupportTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void schedulerAccessorBean() throws Exception {
|
public void schedulerAccessorBean() throws Exception {
|
||||||
Thread.sleep(3000);
|
Thread.sleep(3000);
|
||||||
try (ClassPathXmlApplicationContext ctx = context("schedulerAccessorBean.xml")) {
|
try (ClassPathXmlApplicationContext ctx = context("schedulerAccessorBean.xml")) {
|
||||||
|
|
|
@ -30,7 +30,7 @@ import org.springframework.context.SmartLifecycle;
|
||||||
import org.springframework.core.testfixture.EnabledForTestGroups;
|
import org.springframework.core.testfixture.EnabledForTestGroups;
|
||||||
|
|
||||||
import static org.assertj.core.api.Assertions.assertThat;
|
import static org.assertj.core.api.Assertions.assertThat;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Mark Fisher
|
* @author Mark Fisher
|
||||||
|
@ -252,7 +252,7 @@ public class DefaultLifecycleProcessorTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void smartLifecycleGroupShutdown() throws Exception {
|
public void smartLifecycleGroupShutdown() throws Exception {
|
||||||
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
||||||
TestSmartLifecycleBean bean1 = TestSmartLifecycleBean.forShutdownTests(1, 300, stoppedBeans);
|
TestSmartLifecycleBean bean1 = TestSmartLifecycleBean.forShutdownTests(1, 300, stoppedBeans);
|
||||||
|
@ -282,7 +282,7 @@ public class DefaultLifecycleProcessorTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void singleSmartLifecycleShutdown() throws Exception {
|
public void singleSmartLifecycleShutdown() throws Exception {
|
||||||
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
||||||
TestSmartLifecycleBean bean = TestSmartLifecycleBean.forShutdownTests(99, 300, stoppedBeans);
|
TestSmartLifecycleBean bean = TestSmartLifecycleBean.forShutdownTests(99, 300, stoppedBeans);
|
||||||
|
@ -389,7 +389,7 @@ public class DefaultLifecycleProcessorTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void dependentShutdownFirstEvenIfItsPhaseIsLower() throws Exception {
|
public void dependentShutdownFirstEvenIfItsPhaseIsLower() throws Exception {
|
||||||
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
||||||
TestSmartLifecycleBean beanMin = TestSmartLifecycleBean.forShutdownTests(Integer.MIN_VALUE, 100, stoppedBeans);
|
TestSmartLifecycleBean beanMin = TestSmartLifecycleBean.forShutdownTests(Integer.MIN_VALUE, 100, stoppedBeans);
|
||||||
|
@ -462,7 +462,7 @@ public class DefaultLifecycleProcessorTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void dependentShutdownFirstAndIsSmartLifecycle() throws Exception {
|
public void dependentShutdownFirstAndIsSmartLifecycle() throws Exception {
|
||||||
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
||||||
TestSmartLifecycleBean beanMin = TestSmartLifecycleBean.forShutdownTests(Integer.MIN_VALUE, 400, stoppedBeans);
|
TestSmartLifecycleBean beanMin = TestSmartLifecycleBean.forShutdownTests(Integer.MIN_VALUE, 400, stoppedBeans);
|
||||||
|
@ -526,7 +526,7 @@ public class DefaultLifecycleProcessorTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void dependentShutdownFirstButNotSmartLifecycle() throws Exception {
|
public void dependentShutdownFirstButNotSmartLifecycle() throws Exception {
|
||||||
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
CopyOnWriteArrayList<Lifecycle> stoppedBeans = new CopyOnWriteArrayList<>();
|
||||||
TestSmartLifecycleBean bean1 = TestSmartLifecycleBean.forShutdownTests(1, 200, stoppedBeans);
|
TestSmartLifecycleBean bean1 = TestSmartLifecycleBean.forShutdownTests(1, 200, stoppedBeans);
|
||||||
|
|
|
@ -35,7 +35,7 @@ import org.springframework.scheduling.config.ScheduledTaskRegistrar;
|
||||||
import org.springframework.scheduling.config.TaskManagementConfigUtils;
|
import org.springframework.scheduling.config.TaskManagementConfigUtils;
|
||||||
|
|
||||||
import static org.assertj.core.api.Assertions.assertThat;
|
import static org.assertj.core.api.Assertions.assertThat;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Tests use of @EnableScheduling on @Configuration classes.
|
* Tests use of @EnableScheduling on @Configuration classes.
|
||||||
|
@ -58,7 +58,7 @@ public class EnableSchedulingTests {
|
||||||
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void withFixedRateTask() throws InterruptedException {
|
public void withFixedRateTask() throws InterruptedException {
|
||||||
ctx = new AnnotationConfigApplicationContext(FixedRateTaskConfig.class);
|
ctx = new AnnotationConfigApplicationContext(FixedRateTaskConfig.class);
|
||||||
assertThat(ctx.getBean(ScheduledTaskHolder.class).getScheduledTasks().size()).isEqualTo(2);
|
assertThat(ctx.getBean(ScheduledTaskHolder.class).getScheduledTasks().size()).isEqualTo(2);
|
||||||
|
@ -68,7 +68,7 @@ public class EnableSchedulingTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void withSubclass() throws InterruptedException {
|
public void withSubclass() throws InterruptedException {
|
||||||
ctx = new AnnotationConfigApplicationContext(FixedRateTaskConfigSubclass.class);
|
ctx = new AnnotationConfigApplicationContext(FixedRateTaskConfigSubclass.class);
|
||||||
assertThat(ctx.getBean(ScheduledTaskHolder.class).getScheduledTasks().size()).isEqualTo(2);
|
assertThat(ctx.getBean(ScheduledTaskHolder.class).getScheduledTasks().size()).isEqualTo(2);
|
||||||
|
@ -78,7 +78,7 @@ public class EnableSchedulingTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void withExplicitScheduler() throws InterruptedException {
|
public void withExplicitScheduler() throws InterruptedException {
|
||||||
ctx = new AnnotationConfigApplicationContext(ExplicitSchedulerConfig.class);
|
ctx = new AnnotationConfigApplicationContext(ExplicitSchedulerConfig.class);
|
||||||
assertThat(ctx.getBean(ScheduledTaskHolder.class).getScheduledTasks().size()).isEqualTo(1);
|
assertThat(ctx.getBean(ScheduledTaskHolder.class).getScheduledTasks().size()).isEqualTo(1);
|
||||||
|
@ -97,7 +97,7 @@ public class EnableSchedulingTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void withExplicitScheduledTaskRegistrar() throws InterruptedException {
|
public void withExplicitScheduledTaskRegistrar() throws InterruptedException {
|
||||||
ctx = new AnnotationConfigApplicationContext(ExplicitScheduledTaskRegistrarConfig.class);
|
ctx = new AnnotationConfigApplicationContext(ExplicitScheduledTaskRegistrarConfig.class);
|
||||||
assertThat(ctx.getBean(ScheduledTaskHolder.class).getScheduledTasks().size()).isEqualTo(1);
|
assertThat(ctx.getBean(ScheduledTaskHolder.class).getScheduledTasks().size()).isEqualTo(1);
|
||||||
|
@ -119,7 +119,7 @@ public class EnableSchedulingTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void withAmbiguousTaskSchedulers_andSingleTask_disambiguatedByScheduledTaskRegistrarBean() throws InterruptedException {
|
public void withAmbiguousTaskSchedulers_andSingleTask_disambiguatedByScheduledTaskRegistrarBean() throws InterruptedException {
|
||||||
ctx = new AnnotationConfigApplicationContext(
|
ctx = new AnnotationConfigApplicationContext(
|
||||||
SchedulingEnabled_withAmbiguousTaskSchedulers_andSingleTask_disambiguatedByScheduledTaskRegistrar.class);
|
SchedulingEnabled_withAmbiguousTaskSchedulers_andSingleTask_disambiguatedByScheduledTaskRegistrar.class);
|
||||||
|
@ -129,7 +129,7 @@ public class EnableSchedulingTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void withAmbiguousTaskSchedulers_andSingleTask_disambiguatedBySchedulerNameAttribute() throws InterruptedException {
|
public void withAmbiguousTaskSchedulers_andSingleTask_disambiguatedBySchedulerNameAttribute() throws InterruptedException {
|
||||||
ctx = new AnnotationConfigApplicationContext(
|
ctx = new AnnotationConfigApplicationContext(
|
||||||
SchedulingEnabled_withAmbiguousTaskSchedulers_andSingleTask_disambiguatedBySchedulerNameAttribute.class);
|
SchedulingEnabled_withAmbiguousTaskSchedulers_andSingleTask_disambiguatedBySchedulerNameAttribute.class);
|
||||||
|
@ -139,7 +139,7 @@ public class EnableSchedulingTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void withTaskAddedVia_configureTasks() throws InterruptedException {
|
public void withTaskAddedVia_configureTasks() throws InterruptedException {
|
||||||
ctx = new AnnotationConfigApplicationContext(SchedulingEnabled_withTaskAddedVia_configureTasks.class);
|
ctx = new AnnotationConfigApplicationContext(SchedulingEnabled_withTaskAddedVia_configureTasks.class);
|
||||||
|
|
||||||
|
@ -148,7 +148,7 @@ public class EnableSchedulingTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void withTriggerTask() throws InterruptedException {
|
public void withTriggerTask() throws InterruptedException {
|
||||||
ctx = new AnnotationConfigApplicationContext(TriggerTaskConfig.class);
|
ctx = new AnnotationConfigApplicationContext(TriggerTaskConfig.class);
|
||||||
|
|
||||||
|
@ -157,7 +157,7 @@ public class EnableSchedulingTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void withInitiallyDelayedFixedRateTask() throws InterruptedException {
|
public void withInitiallyDelayedFixedRateTask() throws InterruptedException {
|
||||||
ctx = new AnnotationConfigApplicationContext(FixedRateTaskConfig_withInitialDelay.class);
|
ctx = new AnnotationConfigApplicationContext(FixedRateTaskConfig_withInitialDelay.class);
|
||||||
|
|
||||||
|
|
|
@ -32,7 +32,7 @@ import static org.mockito.Mockito.atLeast;
|
||||||
import static org.mockito.Mockito.mock;
|
import static org.mockito.Mockito.mock;
|
||||||
import static org.mockito.Mockito.never;
|
import static org.mockito.Mockito.never;
|
||||||
import static org.mockito.Mockito.verify;
|
import static org.mockito.Mockito.verify;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Rick Evans
|
* @author Rick Evans
|
||||||
|
@ -84,7 +84,7 @@ class ScheduledExecutorFactoryBeanTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
void oneTimeExecutionIsSetUpAndFiresCorrectly() throws Exception {
|
void oneTimeExecutionIsSetUpAndFiresCorrectly() throws Exception {
|
||||||
Runnable runnable = mock(Runnable.class);
|
Runnable runnable = mock(Runnable.class);
|
||||||
|
|
||||||
|
@ -98,7 +98,7 @@ class ScheduledExecutorFactoryBeanTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
void fixedRepeatedExecutionIsSetUpAndFiresCorrectly() throws Exception {
|
void fixedRepeatedExecutionIsSetUpAndFiresCorrectly() throws Exception {
|
||||||
Runnable runnable = mock(Runnable.class);
|
Runnable runnable = mock(Runnable.class);
|
||||||
|
|
||||||
|
@ -116,7 +116,7 @@ class ScheduledExecutorFactoryBeanTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
void fixedRepeatedExecutionIsSetUpAndFiresCorrectlyAfterException() throws Exception {
|
void fixedRepeatedExecutionIsSetUpAndFiresCorrectlyAfterException() throws Exception {
|
||||||
Runnable runnable = mock(Runnable.class);
|
Runnable runnable = mock(Runnable.class);
|
||||||
willThrow(new IllegalStateException()).given(runnable).run();
|
willThrow(new IllegalStateException()).given(runnable).run();
|
||||||
|
@ -136,7 +136,7 @@ class ScheduledExecutorFactoryBeanTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
void withInitialDelayRepeatedExecutionIsSetUpAndFiresCorrectly() throws Exception {
|
void withInitialDelayRepeatedExecutionIsSetUpAndFiresCorrectly() throws Exception {
|
||||||
Runnable runnable = mock(Runnable.class);
|
Runnable runnable = mock(Runnable.class);
|
||||||
|
|
||||||
|
@ -156,7 +156,7 @@ class ScheduledExecutorFactoryBeanTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
void withInitialDelayRepeatedExecutionIsSetUpAndFiresCorrectlyAfterException() throws Exception {
|
void withInitialDelayRepeatedExecutionIsSetUpAndFiresCorrectlyAfterException() throws Exception {
|
||||||
Runnable runnable = mock(Runnable.class);
|
Runnable runnable = mock(Runnable.class);
|
||||||
willThrow(new IllegalStateException()).given(runnable).run();
|
willThrow(new IllegalStateException()).given(runnable).run();
|
||||||
|
|
|
@ -33,14 +33,14 @@ import static org.assertj.core.api.Assertions.assertThat;
|
||||||
import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
|
import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
|
||||||
import static org.assertj.core.api.Assertions.assertThatIllegalStateException;
|
import static org.assertj.core.api.Assertions.assertThatIllegalStateException;
|
||||||
import static org.mockito.Mockito.mock;
|
import static org.mockito.Mockito.mock;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Rick Evans
|
* @author Rick Evans
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
* @author Chris Beams
|
* @author Chris Beams
|
||||||
*/
|
*/
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public class ScriptFactoryPostProcessorTests {
|
public class ScriptFactoryPostProcessorTests {
|
||||||
|
|
||||||
private static final String MESSAGE_TEXT = "Bingo";
|
private static final String MESSAGE_TEXT = "Bingo";
|
||||||
|
|
|
@ -57,7 +57,7 @@ import static org.mockito.Mockito.inOrder;
|
||||||
import static org.mockito.Mockito.mock;
|
import static org.mockito.Mockito.mock;
|
||||||
import static org.mockito.Mockito.times;
|
import static org.mockito.Mockito.times;
|
||||||
import static org.mockito.Mockito.verify;
|
import static org.mockito.Mockito.verify;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
|
@ -973,7 +973,7 @@ public class DataSourceTransactionManagerTests {
|
||||||
doTestTransactionWithTimeout(1);
|
doTestTransactionWithTimeout(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
private void doTestTransactionWithTimeout(int timeout) throws Exception {
|
private void doTestTransactionWithTimeout(int timeout) throws Exception {
|
||||||
PreparedStatement ps = mock(PreparedStatement.class);
|
PreparedStatement ps = mock(PreparedStatement.class);
|
||||||
given(con.getAutoCommit()).willReturn(true);
|
given(con.getAutoCommit()).willReturn(true);
|
||||||
|
|
|
@ -63,7 +63,7 @@ import static org.mockito.Mockito.inOrder;
|
||||||
import static org.mockito.Mockito.mock;
|
import static org.mockito.Mockito.mock;
|
||||||
import static org.mockito.Mockito.times;
|
import static org.mockito.Mockito.times;
|
||||||
import static org.mockito.Mockito.verify;
|
import static org.mockito.Mockito.verify;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
|
@ -979,7 +979,7 @@ public class JdbcTransactionManagerTests {
|
||||||
doTestTransactionWithTimeout(1);
|
doTestTransactionWithTimeout(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
private void doTestTransactionWithTimeout(int timeout) throws Exception {
|
private void doTestTransactionWithTimeout(int timeout) throws Exception {
|
||||||
PreparedStatement ps = mock(PreparedStatement.class);
|
PreparedStatement ps = mock(PreparedStatement.class);
|
||||||
given(con.getAutoCommit()).willReturn(true);
|
given(con.getAutoCommit()).willReturn(true);
|
||||||
|
|
|
@ -42,7 +42,7 @@ import static org.assertj.core.api.Assertions.assertThat;
|
||||||
import static org.mockito.BDDMockito.given;
|
import static org.mockito.BDDMockito.given;
|
||||||
import static org.mockito.Mockito.verify;
|
import static org.mockito.Mockito.verify;
|
||||||
import static org.mockito.Mockito.verifyNoMoreInteractions;
|
import static org.mockito.Mockito.verifyNoMoreInteractions;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Unit and integration tests for {@link DelegatingWebConnection}.
|
* Unit and integration tests for {@link DelegatingWebConnection}.
|
||||||
|
@ -124,7 +124,7 @@ public class DelegatingWebConnectionTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public void verifyExampleInClassLevelJavadoc() throws Exception {
|
public void verifyExampleInClassLevelJavadoc() throws Exception {
|
||||||
WebClient webClient = new WebClient();
|
WebClient webClient = new WebClient();
|
||||||
|
|
||||||
|
|
|
@ -69,7 +69,7 @@ import org.springframework.web.socket.server.support.DefaultHandshakeHandler;
|
||||||
|
|
||||||
import static org.assertj.core.api.Assertions.assertThat;
|
import static org.assertj.core.api.Assertions.assertThat;
|
||||||
import static org.assertj.core.api.Assertions.fail;
|
import static org.assertj.core.api.Assertions.fail;
|
||||||
import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
import static org.springframework.core.testfixture.TestGroup.LONG_RUNNING;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Abstract base class for integration tests using the
|
* Abstract base class for integration tests using the
|
||||||
|
@ -79,7 +79,7 @@ import static org.springframework.core.testfixture.TestGroup.PERFORMANCE;
|
||||||
* @author Rossen Stoyanchev
|
* @author Rossen Stoyanchev
|
||||||
* @author Sam Brannen
|
* @author Sam Brannen
|
||||||
*/
|
*/
|
||||||
@EnabledForTestGroups(PERFORMANCE)
|
@EnabledForTestGroups(LONG_RUNNING)
|
||||||
public abstract class AbstractSockJsIntegrationTests {
|
public abstract class AbstractSockJsIntegrationTests {
|
||||||
|
|
||||||
protected Log logger = LogFactory.getLog(getClass());
|
protected Log logger = LogFactory.getLog(getClass());
|
||||||
|
|
Loading…
Reference in New Issue