Skip to content

Commit

Permalink
Don't log "Jasmine worker not sending...after disconnect" messages
Browse files Browse the repository at this point in the history
These haven't proven useful and they can cause serious flooding e.g
when the runner terminates execution while a worker is processing a
suite with a lot of fast specs.
  • Loading branch information
sgravrock committed Jul 4, 2024
1 parent 22271c7 commit 9a8edf2
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
7 changes: 0 additions & 7 deletions lib/parallel_worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,9 +121,6 @@ class ParallelWorker {
await env.execute();

if (!this.clusterWorker_.isConnected()) {
console.error(
'Jasmine worker not sending specFileDone message after disconnect'
);
return;
}

Expand Down Expand Up @@ -153,10 +150,6 @@ function forwardingReporter(clusterWorker) {
for (const eventName of eventNames) {
reporter[eventName] = function (payload) {
if (!clusterWorker.isConnected()) {
console.error(
`Jasmine worker not sending ${eventName} reporter event ` +
'after disconnect'
);
return;
}

Expand Down
6 changes: 0 additions & 6 deletions spec/parallel_worker_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -537,9 +537,6 @@ describe('ParallelWorker', function() {
await Promise.resolve();
// No other messages should have been sent
expect(this.clusterWorker.send).toHaveBeenCalledOnceWith({type: 'booted'});
expect(console.error).toHaveBeenCalledOnceWith(
'Jasmine worker not sending specFileDone message after disconnect'
);
});
});

Expand Down Expand Up @@ -591,9 +588,6 @@ describe('ParallelWorker', function() {
dispatchRepoterEvent(env, eventName, payload);

expect(this.clusterWorker.send).not.toHaveBeenCalled();
expect(console.error).toHaveBeenCalledOnceWith(
`Jasmine worker not sending ${eventName} reporter event after disconnect`
);
});
}

Expand Down

0 comments on commit 9a8edf2

Please sign in to comment.