mirror of
https://github.com/nodejs/node.git
synced 2026-10-14 10:26:26 -04:00
test: add regression test for test_runner after hook
Refs: https://github.com/nodejs/node/issues/51997 PR-URL: https://github.com/nodejs/node/pull/51998 Fixes: https://github.com/nodejs/node/issues/51997 Reviewed-By: Matthew Aitken <maitken033380023@gmail.com> Reviewed-By: Richard Lau <rlau@redhat.com> Reviewed-By: Moshe Atlow <moshe@atlow.co.il> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com>
This commit is contained in:
1 parent
0e8070d4f2
commit
3aa06589f1
1 file changed
+12
@@ -0,0 +1,12 @@
|
||||
'use strict';
|
||||
const common = require('../common');
|
||||
const { test } = require('node:test');
|
||||
|
||||
// Regression test for https://github.com/nodejs/node/issues/51997
|
||||
test('after hook should be called with no subtests', (t) => {
|
||||
const timer = setTimeout(common.mustNotCall(), 2 ** 30);
|
||||
|
||||
t.after(common.mustCall(() => {
|
||||
clearTimeout(timer);
|
||||
}));
|
||||
});
|
||||
Reference in new issue
Block a user