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

Side by Side Diff: LayoutTests/http/tests/websocket/handshake-fail-by-more-accept-header.html

Issue 817733004: WebSocket layout tests clean up (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 11 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 <!DOCTYPE HTML> 1 <!DOCTYPE HTML>
2 <html> 2 <html>
3 <head> 3 <head>
4 <script src="/js-test-resources/js-test.js"></script> 4 <script src="/js-test-resources/js-test.js"></script>
5 </head> 5 </head>
6 <body> 6 <body>
7 <div id="description"></div> 7 <div id="description"></div>
8 <div id="console"></div> 8 <div id="console"></div>
9 <script> 9 <script>
10 description("Test that WebSocket handshake fails if there are more one Sec-WebSo cket-Accept header field in the response."); 10 description("Test that WebSocket handshake fails if there are more one Sec-WebSo cket-Accept header field in the response.");
(...skipping 17 matching lines...) Expand all
28 ws.onmessage = function(messageEvent) 28 ws.onmessage = function(messageEvent)
29 { 29 {
30 testFailed("Unexpectedly Received: '" + messageEvent.data + "'"); 30 testFailed("Unexpectedly Received: '" + messageEvent.data + "'");
31 }; 31 };
32 32
33 ws.onclose = function() 33 ws.onclose = function()
34 { 34 {
35 endTest(); 35 endTest();
36 }; 36 };
37 37
38 ws.onerror = function(errorEvent)
39 {
40 testPassed("onerror() was called");
41 };
42
38 function timeOutCallback() 43 function timeOutCallback()
39 { 44 {
40 debug("Timed out in state: " + ws.readyState); 45 debug("Timed out in state: " + ws.readyState);
41 endTest(); 46 endTest();
42 } 47 }
43 48
44 var timeoutID = setTimeout(timeOutCallback, 3000); 49 var timeoutID = setTimeout(timeOutCallback, 3000);
45 50
46 </script> 51 </script>
47 </body> 52 </body>
48 </html> 53 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698