OLD | NEW |
1 <script src="../resources/get-host-info.sub.js"></script> | 1 <script src="/common/get-host-info.sub.js"></script> |
2 <script src="test-helpers.sub.js?pipe=sub"></script> | 2 <script src="test-helpers.sub.js?pipe=sub"></script> |
3 <script> | 3 <script> |
4 var path = base_path() + 'fetch-access-control.py'; | 4 var path = base_path() + 'fetch-access-control.py'; |
5 var host_info = get_host_info(); | 5 var host_info = get_host_info(); |
6 var SUCCESS = 'SUCCESS'; | 6 var SUCCESS = 'SUCCESS'; |
7 var FAIL = 'FAIL'; | 7 var FAIL = 'FAIL'; |
8 | 8 |
9 function create_test_case_promise(url, with_credentials) { | 9 function create_test_case_promise(url, with_credentials) { |
10 return new Promise(function(resolve) { | 10 return new Promise(function(resolve) { |
11 var xhr = new XMLHttpRequest(); | 11 var xhr = new XMLHttpRequest(); |
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
201 promises.push(create_serial_promise(serial_tests)); | 201 promises.push(create_serial_promise(serial_tests)); |
202 Promise.all(promises) | 202 Promise.all(promises) |
203 .then(function() { | 203 .then(function() { |
204 port.postMessage({results: 'finish'}); | 204 port.postMessage({results: 'finish'}); |
205 }) | 205 }) |
206 .catch(function(e) { | 206 .catch(function(e) { |
207 port.postMessage({results: 'failure:' + e}); | 207 port.postMessage({results: 'failure:' + e}); |
208 }); | 208 }); |
209 }, false); | 209 }, false); |
210 </script> | 210 </script> |
OLD | NEW |