From 3a48514a3c170378747a0af5586a33a67127a306 Mon Sep 17 00:00:00 2001
From: Copilot <198982749+Copilot@users.noreply.github.com>
Date: Wed, 17 Dec 2025 12:04:15 +0000
Subject: [PATCH] =?UTF-8?q?=E2=9C=85(worker)=20Bump=20e2e=20test=20timeout?=
=?UTF-8?q?s=20from=201s=20to=205s=20(#6386)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
E2e tests were timing out with "Property timeout: exceeded limit of 1000
milliseconds" errors in CI, particularly in
`nonSerializableButSameData.spec.ts`.
## Changes
- Increased `assertTimeout` from 1000ms to 5000ms across all 13 e2e test
files in `packages/worker/test/e2e/`
- Updated expected error message in `blockEventLoop.spec.ts` to match
new 5000ms timeout value
The 5-second timeout provides adequate execution time for property-based
tests under constrained CI environments.
Original prompt
> bump the timeouts in e2e of worker to 5s, to drop these errors
>
>
> FAIL @fast-check/worker
test/e2e/nonSerializableButSameData.spec.ts[2m > @fast-check/worker[2m
> should produce the same data in worker and main thread
> AssertionError: expected 'Error: Property failed after 1 tests\…' to
match />>>nonSerializableButSameDataProperty…/
>
> - Expected:
> />>>nonSerializableButSameDataProperty=(.*)<<
>
> + Received:
> "Error: Property failed after 1 tests
> { seed: -1454768394, path: \"0\", endOnFailure: true }
> Counterexample: [Symbol.for(\"-962\")]
> Shrunk 0 time(s)
> Got error: Property timeout: exceeded limit of 1000 milliseconds
> at Timeout.
(D:/a/fast-check/fast-check/packages/fast-check/lib/check/property/TimeoutProperty.js:6:30)
> at listOnTimeout (node:internal/timers:605:17)
> at processTimers (node:internal/timers:541:7)
>
> Hint: Enable verbose mode in order to have the list of all failing
values encountered during the run"
>
> [2m❯ test/e2e/nonSerializableButSameData.spec.ts:[2m36:27
> 34| const workerValueRegex = />>>nonSerializableButSameDataPrope…
> 35| expect(message).toMatch(mainValueRegex);
> 36| expect(message).toMatch(workerValueRegex);
> | ^
> 37| const mainValue = mainValueRegex.exec(message)![1];
> 38| const workerValue = workerValueRegex.exec(message)![1];
---
💬 We'd love your input! Share your thoughts on Copilot coding agent in
our [2 minute survey](https://gh.io/copilot-coding-agent-survey).
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: dubzzz <5300235+dubzzz@users.noreply.github.com>
---
packages/worker/test/e2e/asyncThrow.spec.ts | 2 +-
packages/worker/test/e2e/blockEventLoop.spec.ts | 4 ++--
packages/worker/test/e2e/concurrentAssert.spec.ts | 2 +-
packages/worker/test/e2e/failing.spec.ts | 2 +-
packages/worker/test/e2e/noWorker.spec.ts | 2 +-
packages/worker/test/e2e/nonSerializableButSameData.spec.ts | 2 +-
packages/worker/test/e2e/nonSerializableData.spec.ts | 2 +-
packages/worker/test/e2e/passing.spec.ts | 2 +-
packages/worker/test/e2e/predicateIsolation.spec.ts | 2 +-
packages/worker/test/e2e/propertyIsolation.spec.ts | 2 +-
packages/worker/test/e2e/supportPre.spec.ts | 2 +-
packages/worker/test/e2e/syncThrow.spec.ts | 2 +-
packages/worker/test/e2e/unregistered.spec.ts | 2 +-
13 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/packages/worker/test/e2e/asyncThrow.spec.ts b/packages/worker/test/e2e/asyncThrow.spec.ts
index 482d80f8..f6efbf8d 100644
--- a/packages/worker/test/e2e/asyncThrow.spec.ts
+++ b/packages/worker/test/e2e/asyncThrow.spec.ts
@@ -10,7 +10,7 @@ import { asyncThrowProperty } from './__properties__/asyncThrow.mjs';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it(
diff --git a/packages/worker/test/e2e/blockEventLoop.spec.ts b/packages/worker/test/e2e/blockEventLoop.spec.ts
index e9574599..89fc031a 100644
--- a/packages/worker/test/e2e/blockEventLoop.spec.ts
+++ b/packages/worker/test/e2e/blockEventLoop.spec.ts
@@ -11,7 +11,7 @@ import { expectThrowWithCause } from './__test-helpers__/ThrowWithCause.js';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it(
@@ -19,7 +19,7 @@ if (isMainThread) {
async () => {
// Arrange
const options: Parameters = { ...defaultOptions, endOnFailure: true };
- const expectedError = /Property timeout: exceeded limit of 1000 milliseconds/;
+ const expectedError = /Property timeout: exceeded limit of 5000 milliseconds/;
// Act / Assert
await expectThrowWithCause(assert(blockEventLoopProperty, options), expectedError);
diff --git a/packages/worker/test/e2e/concurrentAssert.spec.ts b/packages/worker/test/e2e/concurrentAssert.spec.ts
index f0d063d8..81b94f31 100644
--- a/packages/worker/test/e2e/concurrentAssert.spec.ts
+++ b/packages/worker/test/e2e/concurrentAssert.spec.ts
@@ -10,7 +10,7 @@ import { readerAssert, writerAssert } from './__properties__/concurrentAssert.mj
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it(
diff --git a/packages/worker/test/e2e/failing.spec.ts b/packages/worker/test/e2e/failing.spec.ts
index 7658bb63..d1d9e7e0 100644
--- a/packages/worker/test/e2e/failing.spec.ts
+++ b/packages/worker/test/e2e/failing.spec.ts
@@ -11,7 +11,7 @@ import { expectThrowWithCause } from './__test-helpers__/ThrowWithCause.js';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it(
diff --git a/packages/worker/test/e2e/noWorker.spec.ts b/packages/worker/test/e2e/noWorker.spec.ts
index 5c2516a2..a7ca5965 100644
--- a/packages/worker/test/e2e/noWorker.spec.ts
+++ b/packages/worker/test/e2e/noWorker.spec.ts
@@ -7,7 +7,7 @@ import { expectThrowWithCause } from './__test-helpers__/ThrowWithCause.js';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it.each`
diff --git a/packages/worker/test/e2e/nonSerializableButSameData.spec.ts b/packages/worker/test/e2e/nonSerializableButSameData.spec.ts
index ab4b6082..d942f03f 100644
--- a/packages/worker/test/e2e/nonSerializableButSameData.spec.ts
+++ b/packages/worker/test/e2e/nonSerializableButSameData.spec.ts
@@ -14,7 +14,7 @@ import {
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout, includeErrorInReport: true };
it(
diff --git a/packages/worker/test/e2e/nonSerializableData.spec.ts b/packages/worker/test/e2e/nonSerializableData.spec.ts
index 5e689135..a55b85b4 100644
--- a/packages/worker/test/e2e/nonSerializableData.spec.ts
+++ b/packages/worker/test/e2e/nonSerializableData.spec.ts
@@ -13,7 +13,7 @@ import {
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout, includeErrorInReport: true };
it(
diff --git a/packages/worker/test/e2e/passing.spec.ts b/packages/worker/test/e2e/passing.spec.ts
index 9f245df8..9c2a0a78 100644
--- a/packages/worker/test/e2e/passing.spec.ts
+++ b/packages/worker/test/e2e/passing.spec.ts
@@ -10,7 +10,7 @@ import { passingProperty } from './__properties__/passing.mjs';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it(
diff --git a/packages/worker/test/e2e/predicateIsolation.spec.ts b/packages/worker/test/e2e/predicateIsolation.spec.ts
index cfdd3b6a..2a938b76 100644
--- a/packages/worker/test/e2e/predicateIsolation.spec.ts
+++ b/packages/worker/test/e2e/predicateIsolation.spec.ts
@@ -11,7 +11,7 @@ import { expectThrowWithCause } from './__test-helpers__/ThrowWithCause.js';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it(
diff --git a/packages/worker/test/e2e/propertyIsolation.spec.ts b/packages/worker/test/e2e/propertyIsolation.spec.ts
index 8bcc9609..434f501a 100644
--- a/packages/worker/test/e2e/propertyIsolation.spec.ts
+++ b/packages/worker/test/e2e/propertyIsolation.spec.ts
@@ -11,7 +11,7 @@ import { expectThrowWithCause } from './__test-helpers__/ThrowWithCause.js';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it(
diff --git a/packages/worker/test/e2e/supportPre.spec.ts b/packages/worker/test/e2e/supportPre.spec.ts
index b9079aa1..a0765086 100644
--- a/packages/worker/test/e2e/supportPre.spec.ts
+++ b/packages/worker/test/e2e/supportPre.spec.ts
@@ -10,7 +10,7 @@ import { supportPreProperty } from './__properties__/supportPre.mjs';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout, seed: -340565462 };
it(
diff --git a/packages/worker/test/e2e/syncThrow.spec.ts b/packages/worker/test/e2e/syncThrow.spec.ts
index 15840628..ff9ce7ff 100644
--- a/packages/worker/test/e2e/syncThrow.spec.ts
+++ b/packages/worker/test/e2e/syncThrow.spec.ts
@@ -10,7 +10,7 @@ import { syncThrowProperty } from './__properties__/syncThrow.mjs';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it(
diff --git a/packages/worker/test/e2e/unregistered.spec.ts b/packages/worker/test/e2e/unregistered.spec.ts
index 98a028fa..fbc1b7a7 100644
--- a/packages/worker/test/e2e/unregistered.spec.ts
+++ b/packages/worker/test/e2e/unregistered.spec.ts
@@ -11,7 +11,7 @@ import { expectThrowWithCause } from './__test-helpers__/ThrowWithCause.js';
if (isMainThread) {
describe('@fast-check/worker', () => {
const testTimeout = 30000;
- const assertTimeout = 1000;
+ const assertTimeout = 5000;
const defaultOptions: Parameters = { timeout: assertTimeout };
it(
--
2.51.2