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

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/xmlhttprequest/sync-xhr-revalidate-after-async-xhr.html

Issue 2391523002: Do not revalidate when ResourceLoaderOptions.synchronousPolicy is different (Closed)
Patch Set: git cl format Created 4 years, 2 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
OLDNEW
(Empty)
1 <html>
2 <body>
3 <script src="/js-test-resources/js-test.js"></script>
4 <script>
5 description('Sync XHR should not turn async due to revalidation.');
6 window.jsTestIsAsync = true;
7 const url = '/cache/resources/etag-200.php?' +
8 Math.floor(100000000 * Math.random());
9
10 xhr1 = new XMLHttpRequest();
11 xhr2SendIsReturned = false;
12 xhr1.open('GET', url, true);
13 xhr1.onload = setTimeout(function() {
14 xhr2 = new XMLHttpRequest();
15 xhr2.open('GET', url, false);
16 xhr2.onload = function() {
17 shouldBeFalse("xhr2SendIsReturned");
18 shouldNotBe("xhr1.responseText", "xhr2.responseText");
19 finishJSTest();
20 };
21 xhr2.send();
22 xhr2SendIsReturned = true;
23 }, 0);
24 xhr1.send();
25 </script>
26 </body>
27 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698