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
Fix the build for node 13.x, make travis test 10, 12, 13, stable #263
Conversation
@@ -1,3 +1,5 @@ | |||
language: node_js | |||
node_js: | |||
- '9' | |||
- '10' | |||
- '12' |
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.
Maybe worth explicitly adding 13 as well?
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
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.
node
or latest
may be better than 13
(fail early).
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 added both
d181274
to
c867b48
Compare
This should be good to go, but Travis is down for scheduled maintenance, so I'm going to wait for it to come back up to make sure this gets through CI. |
…wong#263) @JustinBeckwith pointed out in jlfwong#262 that `npm install` was broken in node 13.x, and @DanielRuf pointed in jlfwong#254 that test fail for node 11+ because of a change to stability of sorting. This PR seeks to address both of those. The installation issue was fixed by just regenerating `package-lock.json` without needing to bump any of the direct dependency versions. The test failure issue requires manual intervention. To fix the sort stability issue, I updated the tests to use the stable sort values (these were all the correct values, though some of the test values were incorrect). To make the suite still pass for node 10, I added a hack where I override `Array.prototype.sort` with a stable implementation that's *only* used in tests (See comments in code for a justification for why) ## Test Plan Before this PR: `npm install` on node 13.x fails & `npm run jest` results in test failures After this PR: `npm install` on node 13.x passes & `npm run jest` passes for node 10, 12, and 13.
@JustinBeckwith pointed out in #262 that
npm install
was broken in node 13.x, and @DanielRuf pointed in #254 that test fail for node 11+ because of a change to stability of sorting.This PR seeks to address both of those.
The installation issue was fixed by just regenerating
package-lock.json
without needing to bump any of the direct dependency versions. The test failure issue requires manual intervention.To fix the sort stability issue, I updated the tests to use the stable sort values (these were all the correct values, though some of the test values were incorrect).
To make the suite still pass for node 10, I added a hack where I override
Array.prototype.sort
with a stable implementation that's only used in tests (See comments in code for a justification for why)Test Plan
Before this PR:
npm install
on node 13.x fails &npm run jest
results in test failuresAfter this PR:
npm install
on node 13.x passes &npm run jest
passes for node 10, 12, and 13.