summaryrefslogtreecommitdiff
path: root/test/parallel/test-whatwg-url-custom-searchparams-set.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/parallel/test-whatwg-url-custom-searchparams-set.js')
-rw-r--r--test/parallel/test-whatwg-url-custom-searchparams-set.js10
1 files changed, 5 insertions, 5 deletions
diff --git a/test/parallel/test-whatwg-url-custom-searchparams-set.js b/test/parallel/test-whatwg-url-custom-searchparams-set.js
index ccd3353ecd..39462bf488 100644
--- a/test/parallel/test-whatwg-url-custom-searchparams-set.js
+++ b/test/parallel/test-whatwg-url-custom-searchparams-set.js
@@ -2,24 +2,24 @@
// Tests below are not from WPT.
-const common = require('../common');
+require('../common');
const assert = require('assert');
const URLSearchParams = require('url').URLSearchParams;
{
const params = new URLSearchParams();
- common.expectsError(() => {
+ assert.throws(() => {
params.set.call(undefined);
}, {
code: 'ERR_INVALID_THIS',
- type: TypeError,
+ name: 'TypeError',
message: 'Value of "this" must be of type URLSearchParams'
});
- common.expectsError(() => {
+ assert.throws(() => {
params.set('a');
}, {
code: 'ERR_MISSING_ARGS',
- type: TypeError,
+ name: 'TypeError',
message: 'The "name" and "value" arguments must be specified'
});