Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(711)

Side by Side Diff: chrome/test/data/extensions/api_test/webrequest/cors/load_image.html

Issue 348253002: Add CORS headers to URLRequestRedirectJob. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: EXPECT GURL -> std::string Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | chrome/test/data/extensions/api_test/webrequest/cors/redirect_target.gif » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <script>
2 var img = document.createElement('img');
3 img.crossOrigin = location.search.match(/crossOrigin=(anonymous|use-credentials) /)[1];
4
5 // After verifying that the image is loaded correctly, we
6 // must also check whether the renderer accepts the resource.
7 // The replies are delayed to allow tests to close the tabs in case
8 // the test failed at an early stage.
9 img.onerror = function() {
10 setTimeout(function() {
11 // Should not happen. Failure is signaled to allow the unit tests to con tinue
12 // with the next test, the exact value of the next string does not matte r.
13 new Image().src = '/signal_that_image_failed_to_load';
14 }, 500);
15 };
16 img.onload = function() {
17 setTimeout(function() {
18 // Verified in test_blocking.js
19 new Image().src = '/signal_that_image_loaded_successfully';
20 }, 500);
21 };
22
23 img.src = decodeURIComponent(location.search.match(/src=([^&]+)/)[1]);
24 </script>
OLDNEW
« no previous file with comments | « no previous file | chrome/test/data/extensions/api_test/webrequest/cors/redirect_target.gif » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698