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

Side by Side Diff: net/websockets/websocket_end_to_end_test.cc

Issue 1005113002: WebSocket header continuations test case. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 5 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
« no previous file with comments | « net/data/websocket/header-continuation_wsh.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // End-to-end tests for WebSocket. 5 // End-to-end tests for WebSocket.
6 // 6 //
7 // A python server is (re)started for each test, which is moderately 7 // A python server is (re)started for each test, which is moderately
8 // inefficient. However, it makes these tests a good fit for scenarios which 8 // inefficient. However, it makes these tests a good fit for scenarios which
9 // require special server configurations. 9 // require special server configurations.
10 10
(...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after
463 SpawnedTestServer::kLocalhost, 463 SpawnedTestServer::kLocalhost,
464 GetWebSocketTestDataDirectory()); 464 GetWebSocketTestDataDirectory());
465 ASSERT_TRUE(ws_server.Start()); 465 ASSERT_TRUE(ws_server.Start());
466 466
467 GURL ws_url = ws_server.GetURL("trailing-whitespace"); 467 GURL ws_url = ws_server.GetURL("trailing-whitespace");
468 sub_protocols_.push_back("sip"); 468 sub_protocols_.push_back("sip");
469 EXPECT_TRUE(ConnectAndWait(ws_url)); 469 EXPECT_TRUE(ConnectAndWait(ws_url));
470 EXPECT_EQ("sip", event_interface_->selected_subprotocol()); 470 EXPECT_EQ("sip", event_interface_->selected_subprotocol());
471 } 471 }
472 472
473 // This is a regression test for crbug.com/169448 "WebSockets should support
474 // header continuations"
475 // TODO(ricea): HTTP continuation headers have been deprecated by RFC7230. If
476 // support for continuation headers is removed from Chrome, then this test will
477 // break and should be removed.
478 TEST_F(WebSocketEndToEndTest, DISABLED_ON_ANDROID(HeaderContinuations)) {
479 SpawnedTestServer ws_server(SpawnedTestServer::TYPE_WS,
480 SpawnedTestServer::kLocalhost,
481 GetWebSocketTestDataDirectory());
482 ASSERT_TRUE(ws_server.Start());
483
484 GURL ws_url = ws_server.GetURL("header-continuation");
485
486 EXPECT_TRUE(ConnectAndWait(ws_url));
487 EXPECT_EQ("permessage-deflate; server_max_window_bits=10",
488 event_interface_->extensions());
489 }
490
473 } // namespace 491 } // namespace
474 492
475 } // namespace net 493 } // namespace net
OLDNEW
« no previous file with comments | « net/data/websocket/header-continuation_wsh.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698