Meteor-Community-Packages / meteor-mocha

A Mocha test driver package for Meteor 1.3+. This package reports server AND client test results in the server console and can be used for running tests on a CI server or locally.
https://packosphere.com/meteortesting/mocha
MIT License
66 stars 41 forks source link

Test server crashes on client-side changes #162

Open Albinutte opened 1 month ago

Albinutte commented 1 month ago

Describe the bug

Making code changes on the client side while running test server with another driver crashes it.

To Reproduce

The server is going to crash with this error:

=> Client modified -- refreshing
node:internal/process/promises:394
    triggerUncaughtException(err, true /* fromPromise */);
    ^
{
  stack: "TypeError: Cannot read properties of undefined (reading 'runClient')\n" +
    '    at clientTests (packages/meteortesting:mocha/server.js:153:22)\n' +
    '    at packages/meteortesting:mocha/server.js:244:3\n' +
    '    at packages/inter-process-messaging.js:99:48\n' +
    '    at Set.forEach (<anonymous>)\n' +
    '    at packages/inter-process-messaging.js:99:21\n' +
    '    at processTicksAndRejections (node:internal/process/task_queues:105:5)',
  message: "Cannot read properties of undefined (reading 'runClient')"
}

Expected behavior

Server restarts without a problem.

Desktop (please complete the following information):

Additional context

The error appeared after migrating from Meteor 2.16 and meteortesting:mocha@2.1.0.

github-actions[bot] commented 1 month ago

Thank you for submitting this issue!

We, the Members of Meteor Community Packages take every issue seriously. Our goal is to provide long-term lifecycles for packages and keep up with the newest changes in Meteor and the overall NodeJs/JavaScript ecosystem.

However, we contribute to these packages mostly in our free time. Therefore, we can't guarantee your issues to be solved within certain time.

If you think this issue is trivial to solve, don't hesitate to submit a pull request, too! We will accompany you in the process with reviews and hints on how to get development set up.

Please also consider sponsoring the maintainers of the package. If you don't know who is currently maintaining this package, just leave a comment and we'll let you know