diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2024-09-25 00:44:34 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-25 01:44:34 +0200 |
commit | a4f59c776189dbd99a9bc6ca36e9d36aee4f56a2 (patch) | |
tree | 5ed9fd8a2ed530ad1d969361db0bfc4576c5185a /tests/node_compat | |
parent | 36ebc03f177cc7db5deb93f4d403cafbed756eb5 (diff) |
test: disable 'test-child-process-ipc-next-tick.js' Node compat test (#25856)
This test is super flaky recently.
See https://github.com/denoland/deno/issues/25855 for more details.
Diffstat (limited to 'tests/node_compat')
-rw-r--r-- | tests/node_compat/config.jsonc | 4 | ||||
-rw-r--r-- | tests/node_compat/test/parallel/test-child-process-ipc-next-tick.js | 52 |
2 files changed, 3 insertions, 53 deletions
diff --git a/tests/node_compat/config.jsonc b/tests/node_compat/config.jsonc index 01db5557d..2f94fa2f2 100644 --- a/tests/node_compat/config.jsonc +++ b/tests/node_compat/config.jsonc @@ -43,7 +43,9 @@ // TODO(littledivy): windows ipc streams not yet implemented "test-child-process-fork-ref.js", "test-child-process-fork-ref2.js", - "test-child-process-ipc-next-tick.js", + // TODO(bartlomieju): this test is very flaky on CI + // https://github.com/denoland/deno/issues/25855 + // "test-child-process-ipc-next-tick.js", "test-child-process-ipc.js", "test-child-process-spawnsync-env.js", "test-child-process-stdio-inherit.js", diff --git a/tests/node_compat/test/parallel/test-child-process-ipc-next-tick.js b/tests/node_compat/test/parallel/test-child-process-ipc-next-tick.js deleted file mode 100644 index b8750f9fc..000000000 --- a/tests/node_compat/test/parallel/test-child-process-ipc-next-tick.js +++ /dev/null @@ -1,52 +0,0 @@ -// deno-fmt-ignore-file -// deno-lint-ignore-file - -// Copyright Joyent and Node contributors. All rights reserved. MIT license. -// Taken from Node 18.12.1 -// This file is automatically generated by `tests/node_compat/runner/setup.ts`. Do not modify this file manually. - -'use strict'; - -// Ignore on Windows. -if (process.platform === 'win32') { - process.exit(0); -} - -const common = require('../common'); -const assert = require('assert'); -const cp = require('child_process'); -const NUM_MESSAGES = 10; -const values = []; - -for (let i = 0; i < NUM_MESSAGES; ++i) { - values[i] = i; -} - -if (process.argv[2] === 'child') { - const received = values.map(() => { return false; }); - - process.on('uncaughtException', common.mustCall((err) => { - received[err] = true; - const done = received.every((element) => { return element === true; }); - - if (done) - process.disconnect(); - }, NUM_MESSAGES)); - - process.on('message', (msg) => { - // If messages are handled synchronously, throwing should break the IPC - // message processing. - throw msg; - }); - - process.send('ready'); -} else { - const child = cp.fork(__filename, ['child']); - - child.on('message', common.mustCall((msg) => { - assert.strictEqual(msg, 'ready'); - values.forEach((value) => { - child.send(value); - }); - })); -} |