-
Notifications
You must be signed in to change notification settings - Fork 30.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
node:test: Add suite() function to define suites #51430
Labels
feature request
Issues that request new features to be added to Node.js.
test_runner
Issues and PRs related to the test runner subsystem.
Comments
justinfagnani
added
the
feature request
Issues that request new features to be added to Node.js.
label
Jan 10, 2024
What's wrong with using describe/it syntax if you need the feature they are meant for? |
Why have the alias of |
VoltrexKeyva
added
the
test_runner
Issues and PRs related to the test runner subsystem.
label
Jan 13, 2024
cjihrig
added a commit
to cjihrig/node
that referenced
this issue
Mar 17, 2024
This commit adds a suite() function to the test runner and makes describe() an alias for it. This matches the it() alias for test(). Fixes: nodejs#51430
nodejs-github-bot
pushed a commit
that referenced
this issue
Mar 19, 2024
This commit adds a suite() function to the test runner and makes describe() an alias for it. This matches the it() alias for test(). Fixes: #51430 PR-URL: #52127 Reviewed-By: Chemi Atlow <[email protected]> Reviewed-By: Moshe Atlow <[email protected]>
rdw-msft
pushed a commit
to rdw-msft/node
that referenced
this issue
Mar 26, 2024
This commit adds a suite() function to the test runner and makes describe() an alias for it. This matches the it() alias for test(). Fixes: nodejs#51430 PR-URL: nodejs#52127 Reviewed-By: Chemi Atlow <[email protected]> Reviewed-By: Moshe Atlow <[email protected]>
marco-ippolito
pushed a commit
that referenced
this issue
May 2, 2024
This commit adds a suite() function to the test runner and makes describe() an alias for it. This matches the it() alias for test(). Fixes: #51430 PR-URL: #52127 Reviewed-By: Chemi Atlow <[email protected]> Reviewed-By: Moshe Atlow <[email protected]>
marco-ippolito
pushed a commit
that referenced
this issue
May 3, 2024
This commit adds a suite() function to the test runner and makes describe() an alias for it. This matches the it() alias for test(). Fixes: #51430 PR-URL: #52127 Reviewed-By: Chemi Atlow <[email protected]> Reviewed-By: Moshe Atlow <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
feature request
Issues that request new features to be added to Node.js.
test_runner
Issues and PRs related to the test runner subsystem.
What is the problem this feature will solve?
Right now the node:test docs talk about suites, and include classes like
SuiteContext
, but the only way to define suites is with thedescribe()
BDD-style function.While the docs point out that "
it
is a shorthand fortest()
", there isn't yet asuite()
function thatdescribe()
is a shorthand for.Grouping tests with
test()
isn't the same, since that requires awaiting the subtests, which suites don't require.What is the feature you are proposing to solve the problem?
Add a
test()
export thatdescribe()
is a shorthand for, like howit()
is fortest()
.What alternatives have you considered?
However this doesn't address the issue that there's a missing correspondence between the typical describe/it and suite/test APIs, or that currently suites are a first-class concept, but only available via
describe()
.The text was updated successfully, but these errors were encountered: