OLD | NEW |
1 Test Promise. | 1 Test Promise. |
2 | 2 |
3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". | 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". |
4 | 4 |
5 PASS promise instanceof Promise is true | 5 PASS promise instanceof Promise is true |
6 PASS promise.constructor is Promise | 6 PASS promise.constructor is Promise |
7 PASS thisInInit is promise | 7 PASS thisInInit === promise is false |
| 8 PASS thisInInit === window is true |
8 PASS resolve instanceof Function is true | 9 PASS resolve instanceof Function is true |
9 PASS reject instanceof Function is true | 10 PASS reject instanceof Function is true |
10 PASS new Promise() threw exception TypeError: Promise constructor takes a functi
on argument. | 11 PASS new Promise() threw exception TypeError: Promise constructor takes a functi
on argument. |
11 PASS new Promise(37) threw exception TypeError: Promise constructor takes a func
tion argument. | 12 PASS new Promise(37) threw exception TypeError: Promise constructor takes a func
tion argument. |
12 PASS promise = new Promise(function() { throw Error("foo"); }) did not throw exc
eption. | 13 PASS promise = new Promise(function() { throw Error("foo"); }) did not throw exc
eption. |
13 PASS result.message is "foo" | 14 PASS result.message is "foo" |
14 PASS fulfilled | 15 PASS fulfilled |
15 PASS result is "hello" | 16 PASS result is "hello" |
16 PASS successfullyParsed is true | 17 PASS successfullyParsed is true |
17 | 18 |
18 TEST COMPLETE | 19 TEST COMPLETE |
19 | 20 |
OLD | NEW |