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

Side by Side Diff: LayoutTests/http/tests/eventsource/eventsource-cors-basic-expected.txt

Issue 1300083002: Add suggestion to use "no-cors" with Fetch fails CORS check. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Patch CORS error expectation files to include message about Fetch CORS. Created 5 years, 4 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 CONSOLE ERROR: EventSource cannot load http://127.0.0.1:8080/eventsource/resourc es/es-cors-basic.php?count=1. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://127.0.0.1:8000' is therefore not allo wed access. 1 CONSOLE ERROR: EventSource cannot load http://127.0.0.1:8080/eventsource/resourc es/es-cors-basic.php?count=1. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://127.0.0.1:8000' is therefore not allo wed access. Alternatively, if you want an opaque response, switch to The Fetch A PI in 'no-cors' mode.
2 CONSOLE ERROR: EventSource cannot load http://127.0.0.1:8080/eventsource/resourc es/es-cors-basic.php?count=2. The 'Access-Control-Allow-Origin' header has a val ue 'http://some.other.origin:80' that is not equal to the supplied origin. Origi n 'http://127.0.0.1:8000' is therefore not allowed access. 2 CONSOLE ERROR: EventSource cannot load http://127.0.0.1:8080/eventsource/resourc es/es-cors-basic.php?count=2. The 'Access-Control-Allow-Origin' header has a val ue 'http://some.other.origin:80' that is not equal to the supplied origin. Origi n 'http://127.0.0.1:8000' is therefore not allowed access. Either change the hea der, or, if you want an opaque response, use the Fetch API in 'no-cors' mode.
3 Test that basic EventSource cross-origin requests fail until they are allowed by the Access-Control-Allow-Origin header. 3 Test that basic EventSource cross-origin requests fail until they are allowed by the Access-Control-Allow-Origin header.
4 4
5 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE ". 5 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE ".
6 6
7 7
8 PASS es = new EventSource("http://127.0.0.1:8080/eventsource/resources/es-cors-b asic.php?count=1") did not throw exception. 8 PASS es = new EventSource("http://127.0.0.1:8080/eventsource/resources/es-cors-b asic.php?count=1") did not throw exception.
9 PASS es.withCredentials is false 9 PASS es.withCredentials is false
10 PASS es.readyState is es.CLOSED 10 PASS es.readyState is es.CLOSED
11 PASS count != 3 && count != 4 is true 11 PASS count != 3 && count != 4 is true
12 PASS es = new EventSource("http://127.0.0.1:8080/eventsource/resources/es-cors-b asic.php?count=2") did not throw exception. 12 PASS es = new EventSource("http://127.0.0.1:8080/eventsource/resources/es-cors-b asic.php?count=2") did not throw exception.
13 PASS es.withCredentials is false 13 PASS es.withCredentials is false
14 PASS es.readyState is es.CLOSED 14 PASS es.readyState is es.CLOSED
15 PASS count != 3 && count != 4 is true 15 PASS count != 3 && count != 4 is true
16 PASS es = new EventSource("http://127.0.0.1:8080/eventsource/resources/es-cors-b asic.php?count=3") did not throw exception. 16 PASS es = new EventSource("http://127.0.0.1:8080/eventsource/resources/es-cors-b asic.php?count=3") did not throw exception.
17 PASS es.withCredentials is false 17 PASS es.withCredentials is false
18 PASS evt.origin.indexOf('http://127.0.0.1:8080') === 0 is true 18 PASS evt.origin.indexOf('http://127.0.0.1:8080') === 0 is true
19 PASS evt.data == 'DATA1' && evt.lastEventId == '77' is true 19 PASS evt.data == 'DATA1' && evt.lastEventId == '77' is true
20 PASS count is 4 20 PASS count is 4
21 PASS evt.origin.indexOf('http://127.0.0.1:8080') === 0 is true 21 PASS evt.origin.indexOf('http://127.0.0.1:8080') === 0 is true
22 PASS count is 4 22 PASS count is 4
23 PASS evt.data is "DATA2" 23 PASS evt.data is "DATA2"
24 DONE 24 DONE
25 PASS successfullyParsed is true 25 PASS successfullyParsed is true
26 26
27 TEST COMPLETE 27 TEST COMPLETE
28 28
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698