-
Notifications
You must be signed in to change notification settings - Fork 29.8k
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
path: fixing a test that breaks on some machines. #6067
path: fixing a test that breaks on some machines. #6067
Conversation
A win32-only test was verifying that path.win32._makeLong('C:') would return the current working directory. This would only work if current working directory was also on the C: device. Fix is to grab the device letter for current working directory, and pass that to _makeLong().
@@ -41,6 +41,7 @@ _UpgradeReport_Files/ | |||
ipch/ | |||
*.sdf | |||
*.opensdf | |||
node.VC.opendb |
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.
I this this belongs in your own global gitignore. :)
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.
Sure, I can remove this, but I believe this is an artifact of vs 2015, so anyone using this IDE will need to add this to their .gitignore. Is there precedent here?
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.
And FWIW, this seems to be a common thing to add to .gitignore files. e.g.,http://stackoverflow.com/questions/34975423/visual-studio-2015-git-error-opensomefile-vc-opendb-permission-denied-fa
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.
No opinion from me on whether or not it should be added, but if it should, then let's do it in a separate PR. It's unrelated to the main change here.
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.
would be *.opendb
@nodejs/testing @nodejs/platform-windows |
Minus the |
reverted change to .gitignore. |
Opened a #6070 for the .gitignore change. |
So, what's the process here? I should squash commits & update the commit message to reflect reviewers & reference the PR, and then someone can merge in? Or is there something else I need to do? |
@mike-kaufman Typically, stuff gets left open for 48 hours (longer if there's a weekend involved) before landing. So I think that's where it's at right now. Squashing helps out a little bit, but if you don't do it, the person landing it will do it, so no big deal. |
Thanks @Trott. So who adds in the reviewer details & PR link to the commit message. Is that the person submitting the PR, or the person merging it in? |
@mike-kaufman Usually the person merging it in. |
'\\\\?\\' + process.cwd().toLowerCase()); | ||
const currentDeviceLetter = path.parse(process.cwd()).root.substring(0, 2); | ||
assert.equal(path.win32._makeLong(currentDeviceLetter).toLowerCase(), | ||
'\\\\?\\' + process.cwd().toLowerCase()); |
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 last line was likely an oversight: I see only 2 added spaces, it was correct before.
LGTM minus comment. Thanks for contributing @mike-kaufman ! |
Fixed indentation. |
LGTM |
Test failures look unrelated but I'm no 100% sure - @nodejs/build |
Looks unrelated indeed. LGTM. |
A win32-only test was verifying that path.win32._makeLong('C:') would return the current working directory. This would only work if current working directory was also on the C: device. Fix is to grab the device letter for current working directory, and pass that to _makeLong(). PR-URL: nodejs#6067 Reviewed-By: Trott - Rich Trott <rtrott@gmail.com> Reviewed-By: Joao Reis <reis@janeasystems.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Landed in 1384de2 Thanks for the contribution, @mike-kaufman! |
A win32-only test was verifying that path.win32._makeLong('C:') would return the current working directory. This would only work if current working directory was also on the C: device. Fix is to grab the device letter for current working directory, and pass that to _makeLong(). PR-URL: #6067 Reviewed-By: Trott - Rich Trott <rtrott@gmail.com> Reviewed-By: Joao Reis <reis@janeasystems.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
A win32-only test was verifying that path.win32._makeLong('C:') would return the current working directory. This would only work if current working directory was also on the C: device. Fix is to grab the device letter for current working directory, and pass that to _makeLong(). PR-URL: #6067 Reviewed-By: Trott - Rich Trott <rtrott@gmail.com> Reviewed-By: Joao Reis <reis@janeasystems.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
A win32-only test was verifying that path.win32._makeLong('C:') would return the current working directory. This would only work if current working directory was also on the C: device. Fix is to grab the device letter for current working directory, and pass that to _makeLong(). PR-URL: #6067 Reviewed-By: Trott - Rich Trott <rtrott@gmail.com> Reviewed-By: Joao Reis <reis@janeasystems.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
A win32-only test was verifying that path.win32._makeLong('C:') would return the current working directory. This would only work if current working directory was also on the C: device. Fix is to grab the device letter for current working directory, and pass that to _makeLong(). PR-URL: #6067 Reviewed-By: Trott - Rich Trott <rtrott@gmail.com> Reviewed-By: Joao Reis <reis@janeasystems.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Pull Request check-list
Please make sure to review and check all of these items:
make -j8 test
(UNIX) orvcbuild test nosign
(Windows) pass withthis change (including linting)?
test (or a benchmark) included?
existing APIs, or introduces new ones)?
Caveats:
Affected core subsystem(s)
path
Description of change
A win32-only test was verifying that path.win32._makeLong('C:')
would return the current working directory. This would only work if
current working directory was also on the C: device. Fix is to grab
the device letter for current working directory, and pass that to
_makeLong().