Skip to content

Commit

Permalink
add huge stack test
Browse files Browse the repository at this point in the history
  • Loading branch information
mafintosh committed Oct 10, 2017
1 parent 3722076 commit 445372a
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions test.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,3 +103,20 @@ tape('each with falsey values', function (t) {
})
})

tape('huge stack', function (t) {
var s = through.obj()

for (var i = 0; i < 5000; i++) {
s.write('foo')
}

s.end()

each(s, function (data, cb) {
if (data !== 'foo') t.fail('bad data')
cb()
}, function (err) {
t.error(err, 'no error')
t.end()
})
})

0 comments on commit 445372a

Please sign in to comment.