Skip to content

Commit

Permalink
fix: clean up deprecation warning issues from #9893
Browse files Browse the repository at this point in the history
  • Loading branch information
vkarpov15 committed Feb 8, 2021
1 parent a068e44 commit fe8b97b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test/errors.validation.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -243,16 +243,17 @@ describe('ValidationError', function() {
});

describe('when user code defines a r/o Error#toJSON', function() {
it('shoud not fail', function() {
it('shoud not fail', function(done) {
const err = [];
const child = require('child_process')
.fork('./test/isolated/project-has-error.toJSON.js', { silent: true });
.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.join('');
assert.equal(stderr, '');
assert.equal(code, 0);
done();
});
});
});
Expand Down

0 comments on commit fe8b97b

Please sign in to comment.