Skip to content
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

Document why node:test exists #42902

Open
spencerwilson opened this issue Apr 29, 2022 · 4 comments
Open

Document why node:test exists #42902

spencerwilson opened this issue Apr 29, 2022 · 4 comments
Labels
doc Issues and PRs related to the documentations.

Comments

@spencerwilson
Copy link

spencerwilson commented Apr 29, 2022

Affected URL(s)

https://nodejs.org/api/test.html

Description of the problem

Background

The core module node:test was proposed in #40954 and shipped at Experimental stability in 18.0.0 via #42325. Dozens of people expressed support for the idea via 👍 reactions and written comments. The sentiment of commenters toward the feature is overwhelmingly supportive.

Problem

TL;DR the questions asked in #40954 (comment) seem unanswered, reducing the likelihood that node:test becomes adopted.

It's unclear what problems the project aims to solve by including a test runner in core.

...or should I say—given the broad support shown by participants in #40954 —that they're unclear to me. 😕

@bcomnes had a comment here - #40954 (comment) - that resonated very much with me: It distilled and synthesized a lot of rough ideas that commenters had submitted up to that point. IMO his comment effectively highlights the variety of goals that people might have for the module. It seems to me that the questions he raised remain unanswered.

cc @nodejs/test_runner (which I saw referenced in nodejs/TSC#1194 (comment) as a recently formed team)

meta note: My framing of this as a docs request might not be the best. If this is more suited as a Discussion or other type of issue, please let me know. Thanks.

@spencerwilson spencerwilson added the doc Issues and PRs related to the documentations. label Apr 29, 2022
@bcomnes
Copy link

bcomnes commented Apr 29, 2022

Finger to the wind now that things settled, a few node maintainers wanted a tape like test runner built in for their own tests in the node repo (functionality beyond the built in assert module) and possibly adoption from the wider ecosystem (outside of the original npm test test runner that was intended as the standard test entry point when Issacs was working on node/npm). This isn't an official description, just what it looks like from outside looking in.

@spencerwilson
Copy link
Author

spencerwilson commented Apr 29, 2022

a tape like test runner built in for their own tests in the node repo

Thanks. Ah, that actually does relate to something in pull-requests.md:

One general rule of thumb is that if Node.js itself needs it (due to historic or functional reasons), then it belongs in Node.js.

I'm now wondering if the commenters in the original feature request issue skew toward Node maintainers and away from non-maintainers. Maybe the value/purpose is more self-evident to that first population than it is to the second.

@RaisinTen
Copy link
Contributor

cc @nodejs/test_runner

@ljharb
Copy link
Member

ljharb commented Apr 30, 2022

I think that’s true. The ecosystem itself hasn’t come anywhere close to settling on one preferred test runner pattern, and node should be adding things only after the ecosystem has rough consensus about what it wants.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc Issues and PRs related to the documentations.
Projects
None yet
Development

No branches or pull requests

4 participants