1 | ;
|
2 |
|
3 | var test = require('../../');
|
4 |
|
5 | if (typeof Promise === 'function' && typeof Promise.resolve === 'function') {
|
6 | test('promise', function () {
|
7 | return new Promise(function (resolve, reject) {
|
8 | reject(new Error('rejection message'));
|
9 | });
|
10 | });
|
11 |
|
12 | test('after', function (t) {
|
13 | t.plan(1);
|
14 | t.ok(true);
|
15 | });
|
16 | } else {
|
17 | // if promises aren't supported pass the node-tap test
|
18 | console.log('skip');
|
19 | }
|