-
Notifications
You must be signed in to change notification settings - Fork 88
Conversation
Codecov Report
@@ Coverage Diff @@
## master #33 +/- ##
==========================================
+ Coverage 96.12% 97.21% +1.08%
==========================================
Files 3 3
Lines 284 287 +3
Branches 65 66 +1
==========================================
+ Hits 273 279 +6
+ Misses 11 8 -3
Continue to review full report at Codecov.
|
Note: While this may seem like an obscure case, it resulted in a failure to find a module that was extremely difficult to track down, due to the many levels of indirection involved. |
@@ -80,7 +85,7 @@ module.exports = function normalize(path) { | |||
result.push(part); | |||
} | |||
} | |||
if(result.length === 1 && /^[A-Za-z]:$/.test(result)) | |||
if(result.length === 1 && /^[A-Za-z]:$/.test(result[0])) |
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 add a test for this change?
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 fixed this because passing an array as the argument to test didn't make sense, though in fact it would work since the one element array conversion to string would just equal the string. As far as adding a test case, I can't figure out how to trigger that if statement. None of the existing tests do, and perhaps it is not possible.
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.
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.
you can trigger this case by passing in C:
as the path.
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.
fs.normalize("C:").should.be.eql("C:\\");
Previously, "./../a" was incorrectly transformed to "a". Paths of that form are sometimes seen by the webpack AliasPlugin.
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.
Almost there!
Codecov Report
@@ Coverage Diff @@
## master #33 +/- ##
==========================================
+ Coverage 96.12% 97.21% +1.08%
==========================================
Files 3 3
Lines 284 287 +3
Branches 65 66 +1
==========================================
+ Hits 273 279 +6
+ Misses 11 8 -3
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## master #33 +/- ##
==========================================
+ Coverage 96.24% 97.29% +1.05%
==========================================
Files 4 4
Lines 293 296 +3
Branches 67 68 +1
==========================================
+ Hits 282 288 +6
+ Misses 11 8 -3
Continue to review full report at Codecov.
|
Thanks, after nearly 3 years 🎉 |
Previously, "./../a" was incorrectly transformed to "a". Paths of
that form are sometimes seen by the webpack AliasPlugin.