Skip to content

Commit 526555d

Browse files
author
Phillip Webb
committed
Tweak times in TimedSpringRunnerTests
1 parent c2b56c0 commit 526555d

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

spring-test/src/test/java/org/springframework/test/context/junit4/TimedSpringRunnerTests.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -82,30 +82,30 @@ public void springTimeoutWithNoOp() {
8282
}
8383

8484
// Should Fail due to timeout.
85-
@Test(timeout = 10)
85+
@Test(timeout = 100)
8686
public void jUnitTimeoutWithSleep() throws Exception {
87-
Thread.sleep(20);
87+
Thread.sleep(200);
8888
}
8989

9090
// Should Fail due to timeout.
9191
@Test
92-
@Timed(millis = 10)
92+
@Timed(millis = 100)
9393
public void springTimeoutWithSleep() throws Exception {
94-
Thread.sleep(20);
94+
Thread.sleep(200);
9595
}
9696

9797
// Should Fail due to timeout.
9898
@Test
9999
@MetaTimed
100100
public void springTimeoutWithSleepAndMetaAnnotation() throws Exception {
101-
Thread.sleep(20);
101+
Thread.sleep(200);
102102
}
103103

104104
// Should Fail due to timeout.
105105
@Test
106-
@MetaTimedWithOverride(millis = 10)
106+
@MetaTimedWithOverride(millis = 100)
107107
public void springTimeoutWithSleepAndMetaAnnotationAndOverride() throws Exception {
108-
Thread.sleep(20);
108+
Thread.sleep(200);
109109
}
110110

111111
// Should Fail due to duplicate configuration.
@@ -116,7 +116,7 @@ public void springAndJUnitTimeouts() {
116116
}
117117
}
118118

119-
@Timed(millis = 10)
119+
@Timed(millis = 100)
120120
@Retention(RetentionPolicy.RUNTIME)
121121
private static @interface MetaTimed {
122122
}

0 commit comments

Comments
 (0)