test-errors.mjs 309 B

12345678910111213141516171819
  1. 'use strict';
  2. import test from 'tape-six';
  3. import chain from '../src/index.js';
  4. test('errors: no streams', t => {
  5. t.throws(() => {
  6. chain([]);
  7. t.fail("shouldn't be here");
  8. });
  9. });
  10. test('errors: wrong stream', t => {
  11. t.throws(() => {
  12. chain([1]);
  13. t.fail("shouldn't be here");
  14. });
  15. });