Closed
Description
Version
v20.3.1
Platform
No response
Subsystem
No response
What steps will reproduce the bug?
> const { describe } = require('node:test')
undefined
> describe()
Promise {
<pending>,
[Symbol(async_id_symbol)]: 261,
[Symbol(trigger_async_id_symbol)]: 6
}
> describe.skip()
undefined
How often does it reproduce? Is there a required condition?
No response
What is the expected behavior? Why is that the expected behavior?
By the docs:
test()
returns aPromise
that resolves once the test completes.
and
test.skip([name][, options][, fn])#
Shorthand for skipping a test, same as test([name], { skip: true }[, fn]).
So I expect that shorthands will have the same return type as test/describe/it
functions.
What do you see instead?
Test shorthands return undefined
Additional information
The issue was discovered at DefinitelyTyped/DefinitelyTyped#65871