-
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
Using mocha for running some tests #2837
Closed
StefanStojanovic
wants to merge
1
commit into
nodejs:main
from
JaneaSystems:mefi-github-actions-test
Closed
Using mocha for running some tests #2837
StefanStojanovic
wants to merge
1
commit into
nodejs:main
from
JaneaSystems:mefi-github-actions-test
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
StefanStojanovic
force-pushed
the
mefi-github-actions-test
branch
from
May 5, 2023 13:36
f3031da
to
1a438f3
Compare
cclauss
changed the title
Github actions constant failure investigation
GitHub Actions constant failure investigation
May 9, 2023
StefanStojanovic
force-pushed
the
mefi-github-actions-test
branch
4 times, most recently
from
May 11, 2023 16:02
e186ce0
to
1247646
Compare
4 tasks
StefanStojanovic
force-pushed
the
mefi-github-actions-test
branch
10 times, most recently
from
May 15, 2023 14:45
d639602
to
52ae417
Compare
StefanStojanovic
force-pushed
the
mefi-github-actions-test
branch
4 times, most recently
from
May 16, 2023 15:44
a7e339a
to
1a2445c
Compare
@StefanStojanovic this may be relevant: #2848 |
legobeat
added a commit
to legobeat/node-gyp
that referenced
this pull request
May 17, 2023
This reverts commit 02480f6, thereby rolling back dependency make-fetch-happen from ^11.0.3 to ^10.0.3. The upgrade is breaking for node-fetch users as it has transitive dependencies with syntax incompatible with supported Node.js versions. Related: - nodejs#2770 - nodejs#2837 - nodejs#2816 - nodejs#2848 - nodejs#2827 - nodejs#2796
4 tasks
After make-fetch-happen update GitHub Actions started failing. Updating tap to the latest version and migrating to mocha for addon tests fixes GitHub Action failures.
StefanStojanovic
force-pushed
the
mefi-github-actions-test
branch
from
May 17, 2023 10:24
4994631
to
b26ab05
Compare
StefanStojanovic
changed the title
GitHub Actions constant failure investigation
Using mocha for running some tests
May 17, 2023
3 tasks
Closing in favor of #2851 |
legobeat
added a commit
to legobeat/node-gyp
that referenced
this pull request
Jun 26, 2023
This reverts commit 02480f6, thereby rolling back dependency make-fetch-happen from ^11.0.3 to ^10.0.3. The upgrade is breaking for node-fetch users as it has transitive dependencies with syntax incompatible with supported Node.js versions. Related: - nodejs#2770 - nodejs#2837 - nodejs#2816 - nodejs#2848 - nodejs#2827 - nodejs#2796
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Checklist
npm install && npm test
passesDescription of change
Constant GitHub Action failures started after landing 02480f6. One way to fix this is reverting that commit as proposed in #2849. This PR uses a different approach by keeping the
make-fetch-happen
version and making changes in testing modules.The first thing updated is the
tap
module, from its legacy version 12.7.0 to the latest version 16.3.4. This change fixed the failing tests, but afterward,test-addon.js
started failing randomly in GitHub Actions. Rerunning failed jobs would sometimes fix that, but in some cases, mostly on Windows, they stood broken after many reruns. There was no consistency in this and no pattern was to be found. On the other hand, running thenpm test
locally always passed for me and I tested with various node/python combinations.Since I couldn't reproduce any issues locally, I decided to try changing the testing framework (at least for the failing tests). That brings me to my second change - using
mocha
to runtest-addon.js
which had to be adapted to the new framework. After doing this everything passed in the GitHub Actions without any issues.Other ideas
At this time, the solution isn't pretty but it unblocks the CI, which was my main goal. Potentially, all tests can be migrated to
mocha
eventually, thustap
can be removed completely then. Another idea (proposed in #2851) is to simply usemocha
to run tests we already have (eg.mocha test/test-*
) instead oftap
, and keep tests written intap
.