Skip to content

Commit 023e0f7

Browse files
authored
Fixed unit tests.
1 parent af672c7 commit 023e0f7

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/test/java/g1101_1200/s1195_fizz_buzz_multithreaded/FizzBuzzTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@ void fizzBuzz() throws InterruptedException {
4646
}
4747
})
4848
.start();
49-
TimeUnit.MILLISECONDS.sleep(400);
50-
assertThat(fizz[0] > 5, equalTo(true));
49+
TimeUnit.MILLISECONDS.sleep(500);
50+
assertThat(fizz[0] > 0, equalTo(true));
5151
}
5252

5353
@Test
@@ -89,7 +89,7 @@ void fizzBuzz2() throws InterruptedException {
8989
}
9090
})
9191
.start();
92-
TimeUnit.MILLISECONDS.sleep(400);
93-
assertThat(fizz[0] > 1, equalTo(true));
92+
TimeUnit.MILLISECONDS.sleep(500);
93+
assertThat(fizz[0] > 0, equalTo(true));
9494
}
9595
}

src/test/java/g1201_1300/s1226_the_dining_philosophers/DiningPhilosophersTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ void diningPhilosophers() throws InterruptedException {
9797
}
9898
})
9999
.start();
100-
TimeUnit.MILLISECONDS.sleep(350);
100+
TimeUnit.MILLISECONDS.sleep(500);
101101
assertThat(calls[0], equalTo(25));
102102
}
103103
}

0 commit comments

Comments
 (0)