Skip to content

Commit 8824508

Browse files
committed
improve test coverage
1 parent 64f6bdb commit 8824508

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

test/smoke.test.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,15 @@ describe('on-http-end', () => {
3939
res.end('world')
4040
})
4141

42+
it('should accumulate content and encoding', function (done) {
43+
onFinished(res, (payload) => {
44+
expect(payload.encoding).to.equal('utf-8')
45+
done()
46+
})
47+
48+
res.end('Hello', 'utf-8')
49+
})
50+
4251
it('should accumulate non-string content', function (done) {
4352
onFinished(res, (payload) => {
4453
expect(payload.data).to.equal(true)

0 commit comments

Comments
 (0)