OLD | NEW |
1 importScripts('./js-test-pre.js'); | 1 importScripts('../../../resources/js-test.js'); |
2 | 2 |
3 var global = this; | 3 var global = this; |
4 global.jsTestIsAsync = true; | 4 global.jsTestIsAsync = true; |
5 | 5 |
6 description('Test Promise.'); | 6 description('Test Promise.'); |
7 | 7 |
8 var thisInInit; | 8 var thisInInit; |
9 var resolve, reject; | 9 var resolve, reject; |
10 var promise = new Promise(function(newResolve, newReject) { | 10 var promise = new Promise(function(newResolve, newReject) { |
11 thisInInit = this; | 11 thisInInit = this; |
(...skipping 25 matching lines...) Expand all Loading... |
37 testPassed('fulfilled'); | 37 testPassed('fulfilled'); |
38 shouldBeEqualToString('result', 'hello'); | 38 shouldBeEqualToString('result', 'hello'); |
39 finishJSTest(); | 39 finishJSTest(); |
40 }, function(result) { | 40 }, function(result) { |
41 global.result = result; | 41 global.result = result; |
42 testFailed('rejected'); | 42 testFailed('rejected'); |
43 finishJSTest(); | 43 finishJSTest(); |
44 }); | 44 }); |
45 | 45 |
46 | 46 |
OLD | NEW |