mirror of
https://github.com/SquidDev-CC/CC-Tweaked
synced 2025-03-05 11:08:13 +00:00
Attempt to reduce test flakiness
I'm really not sure why the modem one fails. I can't reproduce outside of CI, so quite hard to debug :/.
This commit is contained in:
parent
717e096b94
commit
4360458416
@ -76,7 +76,7 @@ class Modem_Test {
|
|||||||
*
|
*
|
||||||
* @see [#1278](https://github.com/cc-tweaked/CC-Tweaked/issues/1278)
|
* @see [#1278](https://github.com/cc-tweaked/CC-Tweaked/issues/1278)
|
||||||
*/
|
*/
|
||||||
@GameTest
|
@GameTest(setupTicks = 1)
|
||||||
fun Full_modems_form_networks(helper: GameTestHelper) = helper.sequence {
|
fun Full_modems_form_networks(helper: GameTestHelper) = helper.sequence {
|
||||||
thenExecute {
|
thenExecute {
|
||||||
val modem1 = helper.getBlockEntity(BlockPos(1, 2, 1), ModRegistry.BlockEntities.WIRED_MODEM_FULL.get())
|
val modem1 = helper.getBlockEntity(BlockPos(1, 2, 1), ModRegistry.BlockEntities.WIRED_MODEM_FULL.get())
|
||||||
|
@ -48,7 +48,7 @@ public class ComputerThreadTest {
|
|||||||
assertFalse(timeout.isSoftAborted(), "Should not start soft-aborted");
|
assertFalse(timeout.isSoftAborted(), "Should not start soft-aborted");
|
||||||
|
|
||||||
var delay = ConcurrentHelpers.waitUntil(timeout::isSoftAborted);
|
var delay = ConcurrentHelpers.waitUntil(timeout::isSoftAborted);
|
||||||
assertThat("Should be soft aborted", delay * 1e-9, closeTo(7, 0.5));
|
assertThat("Should be soft aborted", delay * 1e-9, closeTo(7, 1.0));
|
||||||
LOG.info("Slept for {}", delay);
|
LOG.info("Slept for {}", delay);
|
||||||
|
|
||||||
computer.shutdown();
|
computer.shutdown();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user