Skip to content
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

fix: code cleanup in getStrictQuery function #12721

Merged
merged 1 commit into from
Nov 26, 2022

Conversation

lpizzinidev
Copy link
Contributor

Summary
Simple code cleanup as suggested here #12717 (comment)

@lpizzinidev
Copy link
Contributor Author

Hi @vkarpov15

This test seems flaky:

describe('when user code defines a r/o Error#toJSON', function() {
it('should not fail', function(done) {
const err = [];
const child = require('child_process')
.fork('./test/isolated/project-has-error.toJSON.js', ['--no-warnings'], { silent: true });
child.stderr.on('data', function(buf) { err.push(buf); });
child.on('exit', function(code) {
const stderr = err.filter(line => !line.includes('Warning: ')).join('');
assert.equal(stderr, '');
assert.equal(code, 0);
done();
});
});
});

It failed in my last two PRs with a timeout error on this environment Node 16 MongoDB 5.0.11 OS ubuntu-20.04
I'm not able to reproduce it and tests are passing locally.

Any suggestions on how to fix the problem or reproduce the problem locally?
I've tried using this package to trigger actions locally with no luck.
Maybe I should open a related issue?

@vkarpov15
Copy link
Collaborator

@lpizzinidev I'd first suggest increasing the test's timeout using this.timeout(10000). It may just be that the test is slow because it spawns a new process.

Copy link
Collaborator

@vkarpov15 vkarpov15 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 👍

@vkarpov15 vkarpov15 merged commit dc42cb2 into Automattic:master Nov 26, 2022
@vkarpov15 vkarpov15 added this to the 6.7.4 milestone Nov 26, 2022
@lpizzinidev lpizzinidev deleted the fix-cast-cleanup branch November 27, 2022 10:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants