summaryrefslogtreecommitdiff
path: root/test/parallel/test-http2-too-many-settings.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/parallel/test-http2-too-many-settings.js')
-rw-r--r--test/parallel/test-http2-too-many-settings.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/parallel/test-http2-too-many-settings.js b/test/parallel/test-http2-too-many-settings.js
index 0302fe623d..acfd73ada6 100644
--- a/test/parallel/test-http2-too-many-settings.js
+++ b/test/parallel/test-http2-too-many-settings.js
@@ -29,9 +29,10 @@ function doTest(session) {
server.listen(0, common.mustCall(() => {
const client = h2.connect(`http://localhost:${server.address().port}`);
- // On some operating systems, an ECONNRESET error may be emitted.
- // On others it won't be. Do not make this a mustCall
- client.on('error', () => {});
+ client.on('error', common.expectsError({
+ code: 'ERR_HTTP2_SESSION_ERROR',
+ message: 'Session closed with error code 2',
+ }));
client.on('close', common.mustCall(() => server.close()));
}));
}