mirror of
https://github.com/nodejs/node.git
synced 2024-12-01 16:10:02 +01:00
test: increase specificity in dgram test
Expand error message checking to include the entire error string in test-dgram-membership. PR-URL: https://github.com/nodejs/node/pull/11187 Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
parent
fcedd715bb
commit
73f219fb97
@ -14,7 +14,7 @@ const setup = () => {
|
||||
const socket = setup();
|
||||
socket.close(common.mustCall(() => {
|
||||
assert.throws(() => { socket.addMembership(multicastAddress); },
|
||||
/Not running/);
|
||||
/^Error: Not running$/);
|
||||
}));
|
||||
}
|
||||
|
||||
@ -23,7 +23,7 @@ const setup = () => {
|
||||
const socket = setup();
|
||||
socket.close(common.mustCall(() => {
|
||||
assert.throws(() => { socket.dropMembership(multicastAddress); },
|
||||
/Not running/);
|
||||
/^Error: Not running$/);
|
||||
}));
|
||||
}
|
||||
|
||||
@ -31,7 +31,7 @@ const setup = () => {
|
||||
{
|
||||
const socket = setup();
|
||||
assert.throws(() => { socket.addMembership(); },
|
||||
/multicast address must be specified/);
|
||||
/^Error: multicast address must be specified$/);
|
||||
socket.close();
|
||||
}
|
||||
|
||||
@ -39,7 +39,7 @@ const setup = () => {
|
||||
{
|
||||
const socket = setup();
|
||||
assert.throws(() => { socket.dropMembership(); },
|
||||
/multicast address must be specified/);
|
||||
/^Error: multicast address must be specified$/);
|
||||
socket.close();
|
||||
}
|
||||
|
||||
@ -69,7 +69,7 @@ const setup = () => {
|
||||
const socket = setup();
|
||||
assert.throws(
|
||||
() => { socket.dropMembership(multicastAddress); },
|
||||
/EADDRNOTAVAIL/
|
||||
/^Error: dropMembership EADDRNOTAVAIL$/
|
||||
);
|
||||
socket.close();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user