Skip to content

Tests: Refactored to es6 - #9700

Closed
itsmed wants to merge 6 commits into
nodejs:masterfrom
itsmed:strengthen-tests
Closed

Tests: Refactored to es6#9700
itsmed wants to merge 6 commits into
nodejs:masterfrom
itsmed:strengthen-tests

Conversation

@itsmed

Copy link
Copy Markdown
Contributor
Checklist
  • make -j8 test (UNIX), or vcbuild test nosign (Windows) passes
  • tests and/or benchmarks are included
  • documentation is changed or added
  • commit message follows commit guidelines
Affected core subsystem(s)

Tests

Description of change

Changed var to const, assert.equal to assert.strictEqual. Changed anonymous functions to use arrow functions.

@nodejs-github-botnodejs-github-bot added the test Issues and PRs related to the tests. label Nov 19, 2016
@mscdexmscdex added the fs Issues and PRs related to the fs subsystem / file system. label Nov 19, 2016
@mscdex

Copy link
Copy Markdown
Contributor

@cjihrigcjihrig left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you update the commit message according to https://github.com/nodejs/node/blob/master/CONTRIBUTING.md#step-3-commit.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you change { 'fd': fd } to just { fd }.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you replace the throws with common.fail().

@itsmed

Copy link
Copy Markdown
ContributorAuthor

Ok, thanks. Changes made.

@cjihrigcjihrig left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jasnelljasnell left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Almost there...

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The callback here should be wrapped in a common.mustCall()

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The callback should be wrapped in a common.mustCall()

@itsmed

Copy link
Copy Markdown
ContributorAuthor

Ok I think I've got it this time!

@italoacasas

italoacasas commented Jan 16, 2017

Copy link
Copy Markdown

ping @jasnell

@itsmed can you rebase please

itsmedand others added 6 commits January 18, 2017 11:59
Changed var to const, assert.equal to assert.strictEqual
Replaced anonymous functions with arrow functions.
Replaced throw new Error with common.fail.
Replaced anonymous functions with arrow functions.
Replaced throw new Error with common.fail.
Changed var to const, assert.equal to assert.strictEqual
Replaced anonymous functions with arrow functions.
Replaced throw new Error with common.fail.
@itsmed

Copy link
Copy Markdown
ContributorAuthor

@italoacasas rebase done.

@italoacasas

italoacasas commented Jan 18, 2017

Copy link
Copy Markdown

@joyeecheung

Copy link
Copy Markdown
Member

The previous CI job is gone. New CI: https://ci.nodejs.org/job/node-test-pull-request/6230/

@italoacasasitaloacasas added v7.x and removed v7.x labels Feb 6, 2017
@jasnelljasnell added the stalled Issues and PRs that are stalled. label Mar 24, 2017
@fhinkel

Copy link
Copy Markdown
Member

@itsmed thanks for putting this together. Looks like we're missing a ) in line 61. I went ahead and fixed that in the PR, also squashed the commits into one. Landed in d13bd4a

@fhinkelfhinkel closed this Mar 26, 2017
fhinkel pushed a commit that referenced this pull request Mar 26, 2017
Replace anonymous functions with arrow functions.
Replace throw new Error with common.fail.
PR-URL: #9700
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
MylesBorins pushed a commit that referenced this pull request Mar 28, 2017
Replace anonymous functions with arrow functions.
Replace throw new Error with common.fail.
PR-URL: #9700
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
@MylesBorinsMylesBorins mentioned this pull request Mar 28, 2017
@italoacasasitaloacasas mentioned this pull request Apr 10, 2017
2 tasks
MylesBorins pushed a commit that referenced this pull request Apr 18, 2017
Replace anonymous functions with arrow functions.
Replace throw new Error with common.fail.
PR-URL: #9700
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
MylesBorins pushed a commit that referenced this pull request Apr 19, 2017
Replace anonymous functions with arrow functions.
Replace throw new Error with common.fail.
PR-URL: #9700
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
@MylesBorinsMylesBorins mentioned this pull request Apr 19, 2017
andrew749 pushed a commit to michielbaird/node that referenced this pull request Jul 19, 2017
Replace anonymous functions with arrow functions.
Replace throw new Error with common.fail.
PR-URL: nodejs/node#9700
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fsIssues and PRs related to the fs subsystem / file system.stalledIssues and PRs that are stalled.testIssues and PRs related to the tests.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants

@itsmed@mscdex@italoacasas@joyeecheung@fhinkel@jasnell@cjihrig@MylesBorins@nodejs-github-bot