Skip to content

Commit

Permalink
Skip known-bad test on old Node.js versions
Browse files Browse the repository at this point in the history
  • Loading branch information
isaacs committed Jan 6, 2021
1 parent 0c0ca15 commit 43422ff
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/unpack.js
Expand Up @@ -2571,10 +2571,10 @@ t.test('trying to unpack a javascript file should fail', t => {
new Unpack(opts)
.once('error', er => t.match(er, expect, 'async emits'))
.end(dataGzip)
t.throws(() => {
const f = new UnpackSync(opts)
f.end(dataGzip)
}, expect, 'sync throws')
const skip = !/^v([0-9]|1[0-3])\./.test(process.version) ? false
: 'node prior to v14 did not raise sync zlib errors properly'
t.throws(() => new UnpackSync(opts).end(dataGzip),
expect, 'sync throws', {skip})
})

t.test('bad archive if no gzip', t => {
Expand Down

0 comments on commit 43422ff

Please sign in to comment.