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

Side by Side Diff: LayoutTests/fast/xmlhttprequest/xmlhttprequest-responsetype-before-open-sync-request-expected.txt

Issue 206223005: Forbid setting responseType on all sync XHRs. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: waitUntilDone Created 6 years, 9 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
1 This tests that XMLHttpRequest open() disallows synchronous HTTP(S) requests whe n a non-default responseType is set. 1 This tests that XMLHttpRequest open() disallows synchronous HTTP(S) requests whe n a non-default responseType is set.
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 5
6 xhr.responseType = 'document'; 6 xhr.responseType = 'document';
7 PASS xhr.open('GET', 'http://mydomain/', false); threw exception InvalidAccessEr ror: Failed to execute 'open' on 'XMLHttpRequest': Synchronous HTTP requests fro m a document must not set a response type.. 7 PASS xhr.open('GET', 'http://mydomain/', false); threw exception InvalidAccessEr ror: Failed to execute 'open' on 'XMLHttpRequest': Synchronous requests from a d ocument must not set a response type..
8 xhr.responseType = 'document'; 8 xhr.responseType = 'document';
9 PASS xhr.open('GET', 'https://mysecuredomain/', false); threw exception InvalidA ccessError: Failed to execute 'open' on 'XMLHttpRequest': Synchronous HTTP reque sts from a document must not set a response type.. 9 PASS xhr.open('GET', 'https://mysecuredomain/', false); threw exception InvalidA ccessError: Failed to execute 'open' on 'XMLHttpRequest': Synchronous requests f rom a document must not set a response type..
10 PASS window.location.protocol is "file:" 10 PASS window.location.protocol is "file:"
11 xhr.responseType = 'document'; 11 xhr.responseType = 'document';
12 xhr.open('GET', window.location.href, false); 12 PASS xhr.open('GET', window.location.href, false); threw exception InvalidAccess Error: Failed to execute 'open' on 'XMLHttpRequest': Synchronous requests from a document must not set a response type..
13 PASS xhr.responseType is "document"
14 xhr.responseType = 'document'; 13 xhr.responseType = 'document';
15 xhr.open('GET', dataUrl, false); 14 PASS xhr.open('GET', dataUrl, false); threw exception InvalidAccessError: Failed to execute 'open' on 'XMLHttpRequest': Synchronous requests from a document mus t not set a response type..
16 PASS xhr.responseType is "document"
17 PASS successfullyParsed is true 15 PASS successfullyParsed is true
18 16
19 TEST COMPLETE 17 TEST COMPLETE
20 18
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698