Browse Source

ensure pipe methods on stream

See #244
allow-304
Vsevolod Strukchinsky 8 years ago
parent
commit
892813f7b0
  1. 6
      test/stream.js

6
test/stream.js

@ -127,6 +127,12 @@ test.cb('redirect response contains old url', t => {
});
});
test('check for pipe method', t => {
const stream = got.stream(`${s.url}/`);
t.is(typeof stream.pipe, 'function');
t.is(typeof stream.on('error', () => {}).pipe, 'function');
});
test.after('cleanup', async () => {
await s.close();
});

Loading…
Cancel
Save