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

Unified Diff: content/browser/renderer_host/p2p/socket_host_tcp_unittest.cc

Issue 22381012: Allow p2p UDP packages to set DSCP (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: win fix Created 7 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/p2p/socket_host_tcp_unittest.cc
diff --git a/content/browser/renderer_host/p2p/socket_host_tcp_unittest.cc b/content/browser/renderer_host/p2p/socket_host_tcp_unittest.cc
index 1740d23f3f036655e0aeda82f8cff2ffb0ced3c3..cae88bd1c700b4cb379058d853b52b1ba68260be 100644
--- a/content/browser/renderer_host/p2p/socket_host_tcp_unittest.cc
+++ b/content/browser/renderer_host/p2p/socket_host_tcp_unittest.cc
@@ -94,15 +94,15 @@ TEST_F(P2PSocketHostTcpTest, SendStunNoAuth) {
std::vector<char> packet1;
CreateStunRequest(&packet1);
- socket_host_->Send(dest_, packet1, 0);
+ socket_host_->Send(dest_, packet1, net::DSCP_NO_CHANGE, 0);
std::vector<char> packet2;
CreateStunResponse(&packet2);
- socket_host_->Send(dest_, packet2, 0);
+ socket_host_->Send(dest_, packet2, net::DSCP_NO_CHANGE, 0);
std::vector<char> packet3;
CreateStunError(&packet3);
- socket_host_->Send(dest_, packet3, 0);
+ socket_host_->Send(dest_, packet3, net::DSCP_NO_CHANGE, 0);
std::string expected_data;
expected_data.append(IntToSize(packet1.size()));
@@ -125,15 +125,15 @@ TEST_F(P2PSocketHostTcpTest, ReceiveStun) {
std::vector<char> packet1;
CreateStunRequest(&packet1);
- socket_host_->Send(dest_, packet1, 0);
+ socket_host_->Send(dest_, packet1, net::DSCP_NO_CHANGE, 0);
std::vector<char> packet2;
CreateStunResponse(&packet2);
- socket_host_->Send(dest_, packet2, 0);
+ socket_host_->Send(dest_, packet2, net::DSCP_NO_CHANGE, 0);
std::vector<char> packet3;
CreateStunError(&packet3);
- socket_host_->Send(dest_, packet3, 0);
+ socket_host_->Send(dest_, packet3, net::DSCP_NO_CHANGE, 0);
std::string received_data;
received_data.append(IntToSize(packet1.size()));
@@ -171,7 +171,7 @@ TEST_F(P2PSocketHostTcpTest, SendDataNoAuth) {
std::vector<char> packet;
CreateRandomPacket(&packet);
- socket_host_->Send(dest_, packet, 0);
+ socket_host_->Send(dest_, packet, net::DSCP_NO_CHANGE, 0);
EXPECT_EQ(0U, sent_data_.size());
}
@@ -197,7 +197,7 @@ TEST_F(P2PSocketHostTcpTest, SendAfterStunRequest) {
// Now we should be able to send any data to |dest_|.
std::vector<char> packet;
CreateRandomPacket(&packet);
- socket_host_->Send(dest_, packet, 0);
+ socket_host_->Send(dest_, packet, net::DSCP_NO_CHANGE, 0);
std::string expected_data;
expected_data.append(IntToSize(packet.size()));
@@ -219,11 +219,12 @@ TEST_F(P2PSocketHostTcpTest, AsyncWrites) {
std::vector<char> packet1;
CreateStunRequest(&packet1);
- socket_host_->Send(dest_, packet1, 0);
+
+ socket_host_->Send(dest_, packet1, net::DSCP_NO_CHANGE, 0);
std::vector<char> packet2;
CreateStunResponse(&packet2);
- socket_host_->Send(dest_, packet2, 0);
+ socket_host_->Send(dest_, packet2, net::DSCP_NO_CHANGE, 0);
message_loop.RunUntilIdle();
@@ -246,15 +247,15 @@ TEST_F(P2PSocketHostStunTcpTest, SendStunNoAuth) {
std::vector<char> packet1;
CreateStunRequest(&packet1);
- socket_host_->Send(dest_, packet1, 0);
+ socket_host_->Send(dest_, packet1, net::DSCP_NO_CHANGE, 0);
std::vector<char> packet2;
CreateStunResponse(&packet2);
- socket_host_->Send(dest_, packet2, 0);
+ socket_host_->Send(dest_, packet2, net::DSCP_NO_CHANGE, 0);
std::vector<char> packet3;
CreateStunError(&packet3);
- socket_host_->Send(dest_, packet3, 0);
+ socket_host_->Send(dest_, packet3, net::DSCP_NO_CHANGE, 0);
std::string expected_data;
expected_data.append(packet1.begin(), packet1.end());
@@ -274,15 +275,15 @@ TEST_F(P2PSocketHostStunTcpTest, ReceiveStun) {
std::vector<char> packet1;
CreateStunRequest(&packet1);
- socket_host_->Send(dest_, packet1, 0);
+ socket_host_->Send(dest_, packet1, net::DSCP_NO_CHANGE, 0);
std::vector<char> packet2;
CreateStunResponse(&packet2);
- socket_host_->Send(dest_, packet2, 0);
+ socket_host_->Send(dest_, packet2, net::DSCP_NO_CHANGE, 0);
std::vector<char> packet3;
CreateStunError(&packet3);
- socket_host_->Send(dest_, packet3, 0);
+ socket_host_->Send(dest_, packet3, net::DSCP_NO_CHANGE, 0);
std::string received_data;
received_data.append(packet1.begin(), packet1.end());
@@ -317,7 +318,7 @@ TEST_F(P2PSocketHostStunTcpTest, SendDataNoAuth) {
std::vector<char> packet;
CreateRandomPacket(&packet);
- socket_host_->Send(dest_, packet, 0);
+ socket_host_->Send(dest_, packet, net::DSCP_NO_CHANGE, 0);
EXPECT_EQ(0U, sent_data_.size());
}
@@ -335,11 +336,11 @@ TEST_F(P2PSocketHostStunTcpTest, AsyncWrites) {
std::vector<char> packet1;
CreateStunRequest(&packet1);
- socket_host_->Send(dest_, packet1, 0);
+ socket_host_->Send(dest_, packet1, net::DSCP_NO_CHANGE,0);
std::vector<char> packet2;
CreateStunResponse(&packet2);
- socket_host_->Send(dest_, packet2, 0);
+ socket_host_->Send(dest_, packet2, net::DSCP_NO_CHANGE, 0);
message_loop.RunUntilIdle();
« no previous file with comments | « content/browser/renderer_host/p2p/socket_host_tcp_server.cc ('k') | content/browser/renderer_host/p2p/socket_host_udp.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698