Skip to content

Fix npm test if os.cpus().length == 1 #35753

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

Merged
merged 1 commit into from
Feb 13, 2020
Merged

Conversation

jablko
Copy link
Contributor

@jablko jablko commented Dec 18, 2019

Currently it complains

[09:10:20] > node built/local/run.js

TypeScript/src/testRunner/runner.ts:232
        beforeEach(() => {
        ^
ReferenceError: beforeEach is not defined

This change synchronizes scripts/build/tests.jsGulpfile.js with the logic in src/testRunner/runner.ts.

@jablko jablko force-pushed the patch-34 branch 3 times, most recently from 321fe00 to e28375d Compare January 25, 2020 20:23
@sandersn sandersn added the Housekeeping Housekeeping PRs label Feb 1, 2020
@jablko jablko force-pushed the patch-34 branch 5 times, most recently from e5cd93c to ff6f23e Compare February 9, 2020 17:19
@jablko jablko force-pushed the patch-34 branch 4 times, most recently from 8e3396a to ece3100 Compare February 12, 2020 21:42
@sandersn
Copy link
Member

Is the problem that runtests-parallel doesn't work on systems with only 1 CPU? I think runtests should work in this case -- is there some automated context where switching between the two is difficult?

(Having to ask these questions now is one reason why we like to have bugs for every PR, even housekeeping ones.)

@jablko
Copy link
Contributor Author

jablko commented Feb 13, 2020

Sorry, npm test doesn't work on systems with only one CPU. This change effectively makes it use runtests if workers == 1, instead of erroring.

@sandersn
Copy link
Member

Ah, I didn't see that it was npm test. That's a common entry point for first-time contributors, so it's important for it to work.

@sandersn sandersn merged commit 0a7d54d into microsoft:master Feb 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Housekeeping Housekeeping PRs
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants