Uh oh!
There was an error while loading. Please reload this page.
Migration from tap to mocha - #2851
Conversation
24ba185 to
2a4cb64Comparervagg
commented
May 22, 2023
Yeah, I don't think that's a good idea. The files are runnable by themselves, and will execute as soon as they are loaded into process, so all mocha is doing is acting as a "load these files" engine. Actually rewriting the tests to Mocha+Chai (or similar) might be a decent path forward though, I know we've got a bit stuck with tap a few times. |
StefanStojanovic
commented
May 23, 2023
Thanks for that information. I didn't want to rewrite tests initially as I did not know if that is the direction we want to go in. Since it is, I'll change the tests as well. |
7807e01 to
10c9ec0Comparea7c7aaf to
436cc18CompareStefanStojanovic
commented
May 24, 2023
@rvagg I've rewritten tests. I haven't used Regarding the PR, I'm still keeping it as a draft because I want #2650 and #2846 to land first so I can change those tests too, and not leave it to the people who opened those PRs to make needed changes. Besides waiting for those PRs, I consider this work completed. P.S. GitHub makes it look like there are very big changes, but most of them are just indentation and changes from |
9fb124f to
7a05cfcCompareStefanStojanovic
commented
May 25, 2023
@dennisameling and @dsanders11 when you get time, please review the changes I made to the tests you added in #2650 and #2846 respectively. They were supposed to be just changed from |
dsanders11
commented
May 25, 2023
@StefanStojanovic, parallel install tests refactor to |
dennisameling
commented
May 25, 2023
Refactor of the VS2022 tests LGTM ✅️ thank you! |
7a05cfc to
ecbf5ceCompareAfter make-fetch-happen update GitHub Actions started failing. Migrating from tap to mocha testing framework for GitHub Action stability.
Implemented a simple custom mocha test reporter to replace the default one. Made test report more developer friendly.
ecbf5ce to
9e5d65aComparecclauss
commented
May 26, 2023
Will we do a similar migration in the testing of Node.js? Will we be able to drop |
rvagg
commented
May 29, 2023
so for background: tap2junit is used for nice test feedback in jenkins - you can run these tests in ci.nodejs.org and get nice output mocha can do tap output if you want, but none of this is essential, it could all be ditched I think and just get nice mocha output 🤷 |
StefanStojanovic
commented
May 29, 2023
There is no plan to do that for Node.js tests as they are working well.
These tests are run through GitHub Actions, |
rvagg
commented
May 30, 2023
|
cclauss
commented
May 30, 2023
Should these changes be landed on https://github.com/nodejs/gyp-next first? |
StefanStojanovic
commented
May 30, 2023
Are those jobs still in use? They seem outdated and have no build history. Also, I've only seen GitHub Actions in node-gyp repo PRs
I do not know what you mean by this, since these changes change node-gyp tests. From what I saw (went through it very briefly) gyp-next has a |
rvagg
commented
May 31, 2023
https://ci.nodejs.org/job/nodegyp-test-pull-request/ One of the benefits of this is the ability to test a broader range of Node versions and platform permutations than CI allows; which is helpful for a project that depends so much on OS-level inputs like node-gyp does. It hasn't been used much recently because the people that might have used it have slowly faded away, leaving us with CI. |
StefanStojanovic
commented
Jun 1, 2023
Since we've been discussing this PR for some time, and I see no clear objections to the proposed changes, I just wanted to ask if there's something else I should do to get it approved. |
* migrate from tap to mocha After make-fetch-happen update GitHub Actions started failing. Migrating from tap to mocha testing framework for GitHub Action stability. * write custom test reporter for more verbose output Implemented a simple custom mocha test reporter to replace the default one. Made test report more developer friendly.
* migrate from tap to mocha After make-fetch-happen update GitHub Actions started failing. Migrating from tap to mocha testing framework for GitHub Action stability. * write custom test reporter for more verbose output Implemented a simple custom mocha test reporter to replace the default one. Made test report more developer friendly.
Checklist
npm install && npm testpassesDescription of change
After the
make-fetch-happenupdate in 02480f6, GitHub Actions started failing. Migrating fromtaptomochatesting framework as issues only happened in GitHub Actions (tested locally with various node/python combinations, didn't reproduce any failures). This PR is made based on investigation and work done in #2837 as the simplest and probably the cleanest solution. With these changes,Mochareplacestapcompletely, thus restoring GitHub Actions stability.