-
Notifications
You must be signed in to change notification settings - Fork 1.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
GitHub Actions: npm test is failing Windows tests on M1 Macs #3011
Conversation
`npm test` is running and failing Windows `find-visualstudio` tests on an M1 Mac!!! These tests are not being run or not failing on Intel Macs.
Nice! |
@cclauss a quick question - Is the goal of this PR to add the failing configuration, or to address the issue on M1 Mac as well? |
The goal of this pull request is to encourage someone to fix Windows-specific npm tests to only run on Windows or to pass on all operating systems. To me, running Windows tests only on Windows makes sense. This should be done before GitHub Actions migrates all macOS jobs off of Intel and onto ARM. |
Understood. I made a branch from this one. If skipping VS tests outside Windows is wanted, this commit should be enough. Feel free to cherry-pick it, or apply an inline patch file
|
This should satisfy the linter. |
Co-authored-by: Christian Clauss <[email protected]>
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.
LGTM
FWIW, without commenting on whether skipping the test on macOS is the correct thing to do (I trust @StefanStojanovic's judgement here) -- the test failure that was occurring looks to be a mismatch between the test and code: node-gyp/test/test-find-visualstudio.js Lines 479 to 481 in 77737e4
loads test/fixtures/VSSetup_VS_2019_Professional_workload.txt , which contains:
In node-gyp/lib/find-visualstudio.js Lines 357 to 368 in 77737e4
However the test seems to be adding node-gyp/test/test-find-visualstudio.js Lines 499 to 503 in 77737e4
node-gyp/lib/find-visualstudio.js Lines 369 to 378 in 77737e4
Microsoft.VisualStudio.VC.MSBuild.Base .
I suspect the test will fail on Windows on ARM64 (which I don't think is being tested in GitHub Actions). |
I'm not 100% sure, but I also think this is more likely to fail on ARM64 Windows than not. @richardlau thanks for the analysis, we (@huseyinacacak-janea or me) can fix it in a follow-up PR to handle the ARM64 case correctly. Although it is not tested in GH actions, we have access to ARM64 Windows machines where we could develop the change. Once we have it, we can revert b113c39 in order to start testing ARM64 VS detection correctly. Disabling tests now seems like a better approach, as I do not know if we'll get to fixing this before the GitHub Actions migration for macOS. |
GitHub Actions blog: > Over the next 12 weeks, jobs using the `macos-latest` runner label will migrate from macOS 12 (Monterey) to macOS 14 (Sonoma). https://github.blog/changelog/2024-04-01-macos-14-sonoma-is-generally-available-and-the-latest-macos-runner-image * nodejs/node-gyp#3011
* GitHub Actions test on macOS on ARM GitHub Actions blog: > Over the next 12 weeks, jobs using the `macos-latest` runner label will migrate from macOS 12 (Monterey) to macOS 14 (Sonoma). https://github.blog/changelog/2024-04-01-macos-14-sonoma-is-generally-available-and-the-latest-macos-runner-image * nodejs/node-gyp#3011 * exclude: os: macos-14, python-version: [3.8, 3.9] * Also the node-gyp integration tests
A huge hats off to @GeoffreyPlitt for
|
* GitHub Actions: npm test is failing Windows tests on M1 Macs `npm test` is running and failing Windows `find-visualstudio` tests on an M1 Mac!!! These tests are not being run or not failing on Intel Macs. * Only run "Find Visual Studio" tests on Windows * Update test/test-find-visualstudio.js Co-authored-by: Christian Clauss <[email protected]> --------- Co-authored-by: Stefan Stojanovic <[email protected]>
Why are Windows tests running on Macs?
Fixes #2993
npm test
is running and failing Windowsfind-visualstudio
tests on an M1 Mac!!!These tests are either not being run or are not failing on Intel Macs.
GitHub Actions blog:
https://github.blog/changelog/2024-04-01-macos-14-sonoma-is-generally-available-and-the-latest-macos-runner-image
Discovered by @GeoffreyPlitt in:
Checklist
npm install && npm run lint && npm test
passesDescription of change
@jarig