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
Adding where does test go section in writing-test.md #18802
Changes from 3 commits
481c5f9
dd902a0
c1c8eb5
5bf8d98
ca0448b
2dea00a
ba6513b
b24c938
0fa4c3a
c8696df
fc0c5b4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,6 +18,13 @@ Add tests when: | |
- Fixing regressions and bugs. | ||
- Expanding test coverage. | ||
|
||
## Where does the test go | ||
One can refer [test directory structure](https://github.com/nodejs/node/tree/master/test) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. General nit: please keep lines to 80 chars. I think URLs can, maybe, be excepted. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. thanks 👍 |
||
to decide where to put your test cases. If you want to find any current test that exists then | ||
go to the defined [test directory structure](https://github.com/nodejs/node/tree/master/test) | ||
and search for similar APIs and see if there is similar file available. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Overall, this is a bit too verbose and repeats the same information twice. We also do our best to avoid using "you", "your", "one" and similar. We could communicate the same thought in a shorter sentence:
That could probably be improved further. (Note that the link above goes directly to the README rather than the test folder.) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Does above description answers #18774 second issue? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It probably doesn't but I don't think the current one does either. I would go with something like:
It's possible that should be even more detailed, like for example explaining the difference between parallel and sequential, but that could get quite tricky and complicated. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks making changes with the above one. :) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. changes made. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thank you for feedback. |
||
|
||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please keep this consistent with the other places in the doc and only use a single new line :-) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. changes made. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hm, this does not seem to be addressed? |
||
## Test structure | ||
|
||
Let's analyze this basic test from the Node.js test suite: | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This would sound better as "Where are tests located" (maybe "Where are the..." but that's getting clunky) or even "Test directory structure".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changing it to "Test directory structure"