mirror of
https://github.com/nodejs/node.git
synced 2024-11-21 10:59:27 +00:00
test: improve coverage for timer promises schedular
PR-URL: https://github.com/nodejs/node/pull/53370 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
parent
415b82d8b8
commit
b23d1c37b9
@ -7,6 +7,7 @@ const { setTimeout } = require('timers');
|
||||
const {
|
||||
strictEqual,
|
||||
rejects,
|
||||
throws,
|
||||
} = require('assert');
|
||||
|
||||
async function testYield() {
|
||||
@ -48,3 +49,7 @@ async function testCancelableWait2() {
|
||||
}
|
||||
|
||||
testCancelableWait2().then(common.mustCall());
|
||||
|
||||
throws(() => new scheduler.constructor(), {
|
||||
code: 'ERR_ILLEGAL_CONSTRUCTOR',
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user