(exception, fn)
| 549 | describe('should propagate exceptions', function () { |
| 550 | const exceptions = [new TypeError('foobar'), new Error('baz'), { yup: 'ok' }, 'foobarbazqux', '', null, 123.4]; |
| 551 | const expectError = (exception, fn) => { |
| 552 | try { fn(); } catch (ex) { |
| 553 | expect(ex).to.equal(exception); |
| 554 | return; |
| 555 | } |
| 556 | throw new TypeError('Expected table to throw an exception'); |
| 557 | }; |
| 558 | |
| 559 | specify('thrown in the factory function', function () { |
| 560 | exceptions.forEach((exception, index) => { |
no test coverage detected