From 9e796d4575c38c6846f8285192a55a9d4c8b13f9 Mon Sep 17 00:00:00 2001 From: Drew Folta Date: Tue, 19 Sep 2017 13:37:13 -0700 Subject: [PATCH] test: older shared zlib doesnt throw on create When using compiling using `./configure --shared-zlib` older versions of the shared zlib might not through as expected by the test-zlib-failed-init test. Refs: https://github.com/nodejs/node/pull/13697 --- test/parallel/test-zlib-failed-init.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/test/parallel/test-zlib-failed-init.js b/test/parallel/test-zlib-failed-init.js index afc2c82ddfca8e..0ca70ad92d50b9 100644 --- a/test/parallel/test-zlib-failed-init.js +++ b/test/parallel/test-zlib-failed-init.js @@ -1,10 +1,15 @@ 'use strict'; -require('../common'); +const common = require('../common'); const assert = require('assert'); const zlib = require('zlib'); +if (process.config.variables.node_shared_zlib && + /^1\.2\.[0-8]$/.test(process.versions.zlib)) { + common.skip("older versions of shared zlib don't throw on create"); +} + // For raw deflate encoding, requests for 256-byte windows are rejected as // invalid by zlib. // (http://zlib.net/manual.html#Advanced)