promise.js 189 B

123456789101112
  1. import test from '../../..';
  2. test('test', t => {
  3. return Promise.resolve().then(() => {
  4. t.throws(throwSync());
  5. });
  6. });
  7. function throwSync() {
  8. throw new Error('should be detected');
  9. }