Skip to content

Commit 40771c9

Browse files
authored
Disable flaky test on Cygwin (#202)
Unclear why sending a SIGQUIT signal sometimes works and sometimes doesn't but it's probably some kind of race condition in Cygwin's emulation layer. Fixes: #184
1 parent de44a37 commit 40771c9

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tests/test_std.js

+6-1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import * as std from "std";
22
import * as os from "os";
33

44
const isWin = os.platform === 'win32';
5+
const isCygwin = os.platform === 'cygwin';
56

67
function assert(actual, expected, message) {
78
if (arguments.length == 1)
@@ -246,7 +247,11 @@ function test_os_exec()
246247
os.kill(pid, os.SIGTERM);
247248
[ret, status] = os.waitpid(pid, 0);
248249
assert(ret, pid);
249-
assert(status & 0x7f, os.SIGTERM);
250+
// Flaky on cygwin for unclear reasons, see
251+
// https://github.com/quickjs-ng/quickjs/issues/184
252+
if (!isCygwin) {
253+
assert(status & 0x7f, os.SIGTERM);
254+
}
250255
}
251256

252257
function test_timer()

0 commit comments

Comments
 (0)