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

Unified Diff: blimp/client/core/session/assignment_source_unittest.cc

Issue 2462183002: GRPC Stream implementation of HeliumStream
Patch Set: Address gcasto comments Created 4 years, 1 month 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: blimp/client/core/session/assignment_source_unittest.cc
diff --git a/blimp/client/core/session/assignment_source_unittest.cc b/blimp/client/core/session/assignment_source_unittest.cc
index ac4ed390427ed7809ab5caa6dcc2cf8ef06d96af..c2ae076a3300003b109771bf354cedb2e781b02c 100644
--- a/blimp/client/core/session/assignment_source_unittest.cc
+++ b/blimp/client/core/session/assignment_source_unittest.cc
@@ -55,7 +55,8 @@ const char kTestClientAuthTokenPath[] = "blimp/test/data/test_client_token";
MATCHER_P(AssignmentEquals, assignment, "") {
return arg.transport_protocol == assignment.transport_protocol &&
- arg.engine_endpoint == assignment.engine_endpoint &&
+ arg.assignment_options.engine_endpoint ==
+ assignment.assignment_options.engine_endpoint &&
arg.client_auth_token == assignment.client_auth_token &&
((!assignment.cert && !arg.cert) ||
(arg.cert && assignment.cert &&
@@ -191,7 +192,8 @@ class AssignmentSourceTest : public testing::Test {
Assignment AssignmentSourceTest::BuildSslAssignment() {
Assignment assignment;
assignment.transport_protocol = Assignment::TransportProtocol::SSL;
- assignment.engine_endpoint = net::IPEndPoint(kTestIpAddress, kTestPort);
+ assignment.assignment_options.engine_endpoint =
+ net::IPEndPoint(kTestIpAddress, kTestPort);
assignment.client_auth_token = kTestClientAuthToken;
assignment.cert = cert_;
return assignment;
@@ -210,13 +212,13 @@ AssignmentSourceTest::BuildAssignerResponse() {
TEST_F(AssignmentSourceTest, TestTCPAlternateEndpointSuccess) {
Assignment assignment;
assignment.transport_protocol = Assignment::TransportProtocol::TCP;
- assignment.engine_endpoint = net::IPEndPoint(kTestIpAddress, kTestPort);
+ assignment.assignment_options.engine_endpoint =
+ net::IPEndPoint(kTestIpAddress, kTestPort);
assignment.cert = scoped_refptr<net::X509Certificate>(nullptr);
auto* cmd_line = base::CommandLine::ForCurrentProcess();
cmd_line->AppendSwitchASCII(switches::kEngineIP, kTestIpAddressString);
- cmd_line->AppendSwitchASCII(switches::kEnginePort,
- std::to_string(kTestPort));
+ cmd_line->AppendSwitchASCII(switches::kEnginePort, std::to_string(kTestPort));
cmd_line->AppendSwitchASCII(switches::kEngineTransport, kTcpTransportName);
cmd_line->AppendSwitchASCII(kClientAuthTokenPath,
client_auth_token_path_.value());
@@ -235,14 +237,14 @@ TEST_F(AssignmentSourceTest, TestTCPAlternateEndpointSuccess) {
TEST_F(AssignmentSourceTest, TestSSLAlternateEndpointSuccess) {
Assignment assignment;
assignment.transport_protocol = Assignment::TransportProtocol::SSL;
- assignment.engine_endpoint = net::IPEndPoint(kTestIpAddress, kTestPort);
+ assignment.assignment_options.engine_endpoint =
+ net::IPEndPoint(kTestIpAddress, kTestPort);
assignment.cert = cert_;
auto* cmd_line = base::CommandLine::ForCurrentProcess();
cmd_line->AppendSwitchASCII(switches::kEngineIP, kTestIpAddressString);
- cmd_line->AppendSwitchASCII(switches::kEnginePort,
- std::to_string(kTestPort));
+ cmd_line->AppendSwitchASCII(switches::kEnginePort, std::to_string(kTestPort));
cmd_line->AppendSwitchASCII(switches::kEngineTransport, kSslTransportName);
cmd_line->AppendSwitchASCII(switches::kEngineCertPath, cert_path_.value());
cmd_line->AppendSwitchASCII(kClientAuthTokenPath,
« no previous file with comments | « blimp/client/core/session/assignment_source.cc ('k') | blimp/client/core/session/client_network_components.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698