mirror of
https://github.com/nodejs/node.git
synced 2026-11-26 21:58:26 -05:00
Signed-off-by: Matteo Collina <hello@matteocollina.com> PR-URL: https://github.com/nodejs/node/pull/59272 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Chemi Atlow <chemi@atlow.co.il> Reviewed-By: Moshe Atlow <moshe@atlow.co.il> Reviewed-By: Aviv Keller <me@aviv.sh> Reviewed-By: Paolo Insogna <paolo@cowtech.it>
15 lines
554 B
JavaScript
15 lines
554 B
JavaScript
'use strict';
|
|
require('../common');
|
|
const fixtures = require('../common/fixtures');
|
|
const assert = require('node:assert');
|
|
const { spawnSync } = require('node:child_process');
|
|
const { test } = require('node:test');
|
|
|
|
test('mock timers do not break test timeout cleanup', async () => {
|
|
const fixture = fixtures.path('test-runner', 'mock-timers-with-timeout.js');
|
|
const cp = spawnSync(process.execPath, ['--test', fixture], {
|
|
timeout: 30_000,
|
|
});
|
|
assert.strictEqual(cp.status, 0, `Test failed:\nstdout: ${cp.stdout}\nstderr: ${cp.stderr}`);
|
|
});
|