Skip to content

Commit

Permalink
test that streams emit end
Browse files Browse the repository at this point in the history
  • Loading branch information
mafintosh committed Jun 17, 2023
1 parent 2a1b1e9 commit 2fee69b
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion test/extract.js
Expand Up @@ -251,7 +251,7 @@ test('pax', function (t) {
})

test('types', function (t) {
t.plan(3)
t.plan(5)

const extract = tar.extract()
let noEntries = false
Expand Down Expand Up @@ -283,6 +283,9 @@ test('types', function (t) {
stream.on('data', function () {
t.ok(false)
})
stream.on('end', function () {
t.pass('ended')
})
extract.once('entry', onlink)
cb()
}
Expand All @@ -306,6 +309,9 @@ test('types', function (t) {
stream.on('data', function () {
t.ok(false)
})
stream.on('end', function () {
t.pass('ended')
})
noEntries = true
cb()
}
Expand Down

0 comments on commit 2fee69b

Please sign in to comment.