GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — test: check parameter type of fs.mkdir() by shisama · Pull Request #22616 · nodejs/node

Conversation

@shisama

@shisama shisama commented Aug 31, 2018

Copy link
Copy Markdown
Contributor

Added tests to check parameter type of fs.mkdir(), fs.mkdirSync()
and fsPromises.mkdir() to increase coverage.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Masashi Hirano
test: check parameter type of fs.mkdir()
6cb82ab
Added tests to check parameter type of fs.mkdir(), fs.mkdirSync()
and fsPromises.mkdir() to increase coverage.
@nodejs-github-bot nodejs-github-bot added the test Issues and PRs related to Node.js core tests and test infrastructure. label Aug 31, 2018
cjihrig
cjihrig approved these changes Aug 31, 2018
View reviewed changes

@cjihrig cjihrig left a comment

Copy link
Copy Markdown
Contributor

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.

A couple nits. LGTM once the CI passes.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread test/parallel/test-fs-mkdir.js Outdated
const pathname = path.join(tmpdir.path, nextdir());
['', 1, {}, [], null, Symbol('test'), () => {}].forEach((i) => {
common.expectsError(
() => fs.mkdir(pathname, { recursive: i }, common.mustNotCall()),

@cjihrig cjihrig Aug 31, 2018

Copy link
Copy Markdown
Contributor

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.

Could you rename i to recursive, and this can just be { recursive }.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

shisama and BridgeAR reacted with thumbs up emoji
All reactions
  • 👍 2 reactions

@shisama shisama Aug 31, 2018

Copy link
Copy Markdown
Contributor Author

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.

Thank you for your review. Fixed this.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread test/parallel/test-fs-promises.js Outdated
const dir = path.join(tmpDir, nextdir(), nextdir());
['', 1, {}, [], null, Symbol('test'), () => {}].forEach((i) => {
assert.rejects(
// mkdtemp() expects to get a string prefix.

@cjihrig cjihrig Aug 31, 2018

Copy link
Copy Markdown
Contributor

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.

mkdtemp()?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@shisama shisama Aug 31, 2018 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor Author

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.

oh, sorry. this is wrong copy and paste. Fixed this.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
BridgeAR
BridgeAR approved these changes Aug 31, 2018
View reviewed changes
Masashi Hirano added 2 commits August 31, 2018 23:33
Masashi Hirano
test: recursive argument name to check type in fs.mkdir
df5ee0f
Masashi Hirano
test: comment to check type for fsPromises.mkdir()
99708c6
BridgeAR
BridgeAR reviewed Aug 31, 2018
View reviewed changes
Comment thread test/parallel/test-fs-promises.js Outdated
['', 1, {}, [], null, Symbol('test'), () => {}].forEach((recursive) => {
assert.rejects(
// mkdir() expects to get a boolean value for options.recursive.
async () => mkdir(dir, { recursive: i }),

@BridgeAR BridgeAR Aug 31, 2018

Copy link
Copy Markdown
Member

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.

Small oversight: it should be recursive without : i

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@shisama shisama Aug 31, 2018

Copy link
Copy Markdown
Contributor Author

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.

Thank you for your review. I fixed this.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Masashi Hirano
test: fix fs.mkdir recursive option in test-fs-promises
2299b07
@BridgeAR BridgeAR added the author ready PRs with CI started, the required approvals, and no outstanding review comments. label Aug 31, 2018
@BridgeAR

BridgeAR commented Aug 31, 2018

Copy link
Copy Markdown
Member

CI https://ci.nodejs.org/job/node-test-pull-request/16903/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

jasnell
jasnell approved these changes Sep 4, 2018
View reviewed changes
trivikr
trivikr approved these changes Sep 4, 2018
View reviewed changes
gdams
gdams approved these changes Sep 4, 2018
View reviewed changes
@gdams

gdams commented Sep 4, 2018

Copy link
Copy Markdown
Member

landed in: fdf829e

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@gdams gdams closed this Sep 4, 2018
gdams pushed a commit that referenced this pull request Sep 4, 2018
Masashi Hirano George Adams
test: check parameter type of fs.mkdir()
fdf829e
Added tests to check parameter type of fs.mkdir(), fs.mkdirSync()
and fsPromises.mkdir() to increase coverage.

PR-URL: #22616
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: George Adams <[email protected]>
targos pushed a commit that referenced this pull request Sep 12, 2018
Masashi Hirano @targos
test: check parameter type of fs.mkdir()
42e6ce2
Added tests to check parameter type of fs.mkdir(), fs.mkdirSync()
and fsPromises.mkdir() to increase coverage.

PR-URL: #22616
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: George Adams <[email protected]>
@targos targos mentioned this pull request Sep 18, 2018
Release proposal: v10.11.0 #22932
Merged
targos pushed a commit that referenced this pull request Sep 19, 2018
Masashi Hirano @targos
test: check parameter type of fs.mkdir()
8d64c40
Added tests to check parameter type of fs.mkdir(), fs.mkdirSync()
and fsPromises.mkdir() to increase coverage.

PR-URL: #22616
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: George Adams <[email protected]>
@targos targos added the dont-land-on-v10.x label Sep 20, 2018
@targos

targos commented Sep 20, 2018

Copy link
Copy Markdown
Member

Depends on #21875. Marking dont-land-on-v10.x for now.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@targos targos mentioned this pull request Sep 20, 2018
fs: implement recursive (mkdirp) functionality #21875
Closed
4 tasks done
@targos targos removed the dont-land-on-v10.x label Sep 25, 2018
targos pushed a commit that referenced this pull request Sep 25, 2018
Masashi Hirano @targos
test: check parameter type of fs.mkdir()
adaf530
Added tests to check parameter type of fs.mkdir(), fs.mkdirSync()
and fsPromises.mkdir() to increase coverage.

PR-URL: #22616
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: George Adams <[email protected]>
@targos targos mentioned this pull request Oct 7, 2018
Release proposal: v10.12.0 #23313
Merged
This was referenced Oct 10, 2018
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-nodejs#225
Closed
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-android-nodejs#239
Closed
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-nodejs#226
Closed
This was referenced Oct 11, 2018
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-android-nodejs#240
Closed
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-nodejs#227
Closed
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-android-nodejs#241
Closed
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-android-nodejs#242
Closed
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-nodejs#228
Closed
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-android-nodejs#243
Closed
2018-10-10 Version 10.12.0 (Current) @targos beevelop/docker-nodejs#229
Closed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@BridgeAR BridgeAR BridgeAR approved these changes
@jasnell jasnell jasnell approved these changes
@cjihrig cjihrig cjihrig approved these changes
@trivikr trivikr trivikr approved these changes
+1 more reviewer
@gdams gdams gdams approved these changes
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

author ready PRs with CI started, the required approvals, and no outstanding review comments. test Issues and PRs related to Node.js core tests and test infrastructure.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

8 participants

@shisama @BridgeAR @gdams @targos @jasnell @cjihrig @trivikr @nodejs-github-bot
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.