test: add 2nd argument to throws in test-assert

PR-URL: https://github.com/nodejs/node/pull/11061
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
Marlena Compton authored and Myles Borins committed 2017-03-08 17:10:53 -08:00
1 parent 3e9ce770f7
commit 8cce29587c
1 file changed
+4 -2
+4 -2
View File
@@ -97,9 +97,11 @@ assert.throws(makeBlock(a.deepEqual, /a/m, /a/));
assert.throws(makeBlock(a.deepEqual, /a/igm, /a/im));
{
const re1 = /a/;
const re1 = /a/g;
re1.lastIndex = 3;
assert.throws(makeBlock(a.deepEqual, re1, /a/));
assert.throws(makeBlock(a.deepEqual, re1, /a/g),
/^AssertionError: \/a\/g deepEqual \/a\/g$/);
}