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: refactor test-beforeexit-event-exit.js by cjihrig · Pull Request #10577 · nodejs/node

Conversation

@cjihrig

@cjihrig cjihrig commented Jan 2, 2017

Copy link
Copy Markdown
Contributor
Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

test

Sorry, something went wrong.

Uh oh!

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

All reactions
@nodejs-github-bot nodejs-github-bot added lts-watch-v6.x labels Jan 2, 2017
italoacasas
italoacasas approved these changes Jan 2, 2017
View reviewed changes
@italoacasas italoacasas added the process Issues and PRs related to the process subsystem. label Jan 2, 2017
gibfahn
gibfahn approved these changes Jan 2, 2017
View reviewed changes
@Trott

Trott commented Jan 2, 2017

Copy link
Copy Markdown
Member

Perhaps too tangentially related to this change, but since "refactor" is general, perhaps not?:

We have (at least) three test files for the beforeExit event and they are all (IMO) sub-optimally named:

  • test-processs-before-exit.js
  • test-beforeexit-event-exit.js
  • test-beforeexit-event.js

Perhaps we can take this opportunity to rename them all to test-process-beforeExit-*?

All reactions

Sorry, something went wrong.

Uh oh!

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

@cjihrig

cjihrig commented Jan 2, 2017

Copy link
Copy Markdown
Contributor Author

A search for 'beforeExit' in the test directory returned 9 files. If you let me know exactly which ones you want renamed (just the three you mentioned above?), I can rename them in another commit.

All reactions

Sorry, something went wrong.

Uh oh!

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

@Trott

Trott commented Jan 3, 2017

Copy link
Copy Markdown
Member

@cjihrig Looking more closely at it, two of the tests are awfully similar and could/should probably be merged. I have a feeling once we start pulling on this thread, lots of other things may shake out, so, uh, yeah, never mind. :-D I'll probably try to sort it out after this lands.

All reactions

Sorry, something went wrong.

Uh oh!

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

@Trott

Trott commented Jan 3, 2017

Copy link
Copy Markdown
Member

(Actually, if you could just rename this test to test/parallel/test-process-beforeExit-exit.js, that would be great. I'll rename the others.)

All reactions

Sorry, something went wrong.

Uh oh!

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

@sam-github

sam-github commented Jan 3, 2017

Copy link
Copy Markdown
Contributor

I commented elsewhere, but it looks to me like use of camelCase in the test folder is unconventional, most of the project sticks to non-case-sensitive filenaming conventions. Wouldn't we better getting rid of the camelCase, converting to minus-seperators, the dominant convention?

All reactions

Sorry, something went wrong.

Uh oh!

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

thefourtheye
thefourtheye approved these changes Jan 3, 2017
View reviewed changes
Comment thread test/parallel/test-beforeexit-event-exit.js Outdated

@thefourtheye thefourtheye Jan 3, 2017

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.

common.mustCall(..., 0) also will work in this case I guess.

Sorry, something went wrong.

Uh oh!

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

All reactions
jasnell
jasnell approved these changes Jan 3, 2017
View reviewed changes
@Trott

Trott commented Jan 4, 2017

Copy link
Copy Markdown
Member

I commented elsewhere, but it looks to me like use of camelCase in the test folder is unconventional, most of the project sticks to non-case-sensitive filenaming conventions. Wouldn't we better getting rid of the camelCase, converting to minus-seperators, the dominant convention?

@sam-github You make some good points here and elsewhere. The counterargument is that knowing to do that conversion is one more piece of friction. "I know I'm looking for a beforeExit test. Let's look for tests with beforeExit in the name! None? OK. Maybe it's beforeexit. Or before-exit. Or something, I guess?" I'd rather there be just one and only one name for the event/method/whatever, not different names depending on if I'm looking for a filename or not.

I don't feel that strongly enough about it to push for it, and in the absence of a champion, status quo wins out. Sadly, it's not just the 43 mixed case files to consider changing. It's also lowercase everything vs. kebab-case everything: test-fs-readfilesync-pipe-large.js or test-fs-read-file-sync-hostname.js. :-(

TL;DR: We can leave this filename as is. :-D

gibfahn reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

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

@sam-github

sam-github commented Jan 4, 2017

Copy link
Copy Markdown
Contributor

Let's look for tests with beforeExit in the name! None? OK. Maybe it's beforeexit. Or before-exit. Or something, I guess?

agreed, the mapping should be clear and consistent. Could be I've been burned to badly with projects that literally could not be checked out on OS X or Windows because of case changes, and yes, that was with Subversion, but my interactions with tooling on mixed case projects have been poor at times.

In this case, if there is a majority practice, I'd document it, and then we can evolve towards it.

All reactions

Sorry, something went wrong.

Uh oh!

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

@cjihrig
cjihrig force-pushed the beforeexit branch from 9efa1fc to 3ba13e3 Compare January 5, 2017 16:33
@nodejs-github-bot nodejs-github-bot added dont-land-on-v7.x and removed lts-watch-v6.x labels Jan 5, 2017
@cjihrig

cjihrig commented Jan 5, 2017

Copy link
Copy Markdown
Contributor Author

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

All reactions

Sorry, something went wrong.

Uh oh!

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

@cjihrig
test: refactor test-beforeexit-event-exit.js
7f69972
PR-URL: nodejs#10577
Reviewed-By: Italo A. Casas <[email protected]>
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@cjihrig
cjihrig force-pushed the beforeexit branch from 3ba13e3 to 7f69972 Compare January 5, 2017 17:05
@nodejs-github-bot nodejs-github-bot added the dont-land-on-v7.x label Jan 5, 2017
@cjihrig
cjihrig merged commit 7f69972 into nodejs:master Jan 5, 2017
@cjihrig
cjihrig deleted the beforeexit branch January 5, 2017 17:07
@mscdex mscdex added test Issues and PRs related to Node.js core tests and test infrastructure. and removed dont-land-on-v7.x labels Jan 13, 2017
italoacasas pushed a commit to italoacasas/node that referenced this pull request Jan 18, 2017
@cjihrig Italo A. Casas
test: refactor test-beforeexit-event-exit.js
404867b
PR-URL: nodejs#10577
Reviewed-By: Italo A. Casas <[email protected]>
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: James M Snell <[email protected]>
italoacasas pushed a commit to italoacasas/node that referenced this pull request Jan 19, 2017
@cjihrig Italo A. Casas
test: refactor test-beforeexit-event-exit.js
9f3a43a
PR-URL: nodejs#10577
Reviewed-By: Italo A. Casas <[email protected]>
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@italoacasas italoacasas mentioned this pull request Jan 25, 2017
Proposal to update v7.x-staging #10989
Closed
targos pushed a commit that referenced this pull request Jan 28, 2017
@cjihrig @targos
test: refactor test-beforeexit-event-exit.js
045f5f7
PR-URL: #10577
Reviewed-By: Italo A. Casas <[email protected]>
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@italoacasas italoacasas mentioned this pull request Jan 29, 2017
v7.5.0 proposal #11062
Merged
italoacasas pushed a commit to italoacasas/node that referenced this pull request Jan 30, 2017
@cjihrig Italo A. Casas
test: refactor test-beforeexit-event-exit.js
af2bea7
PR-URL: nodejs#10577
Reviewed-By: Italo A. Casas <[email protected]>
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: James M Snell <[email protected]>
italoacasas pushed a commit to italoacasas/node that referenced this pull request Jan 30, 2017
@cjihrig Italo A. Casas
test: refactor test-beforeexit-event-exit.js
da3908c
PR-URL: nodejs#10577
Reviewed-By: Italo A. Casas <[email protected]>
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@MylesBorins MylesBorins added lts-watch-v4.x labels Mar 8, 2017
MylesBorins pushed a commit that referenced this pull request Apr 13, 2017
@cjihrig @MylesBorins
test: refactor test-beforeexit-event-exit.js
3cde69a
PR-URL: #10577
Reviewed-By: Italo A. Casas <[email protected]>
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@MylesBorins MylesBorins added land-on-v6.x and removed lts-watch-v4.x labels Apr 13, 2017
MylesBorins pushed a commit that referenced this pull request Apr 19, 2017
@cjihrig @MylesBorins
test: refactor test-beforeexit-event-exit.js
afea1d0
PR-URL: #10577
Reviewed-By: Italo A. Casas <[email protected]>
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@MylesBorins MylesBorins mentioned this pull request Apr 19, 2017
v6.10.3 proposal #12498
Merged
andrew749 pushed a commit to michielbaird/node that referenced this pull request Jul 19, 2017
@cjihrig @andrew749
test: refactor test-beforeexit-event-exit.js
d237d27
PR-URL: nodejs/node#10577
Reviewed-By: Italo A. Casas <[email protected]>
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@jasnell jasnell jasnell approved these changes
+3 more reviewers
@thefourtheye thefourtheye thefourtheye approved these changes
@italoacasas italoacasas italoacasas approved these changes
@gibfahn gibfahn gibfahn 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

process Issues and PRs related to the process subsystem. 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.

10 participants

@cjihrig @Trott @sam-github @jasnell @thefourtheye @italoacasas @gibfahn @mscdex @MylesBorins @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 01402503 — 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.