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

Side by Side Diff: components/grpc_support/test/get_stream_engine.cc

Issue 2494153002: Testing for component_unittest on CQ
Patch Set: 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 unified diff | Download patch
« no previous file with comments | « no previous file | 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #include "base/lazy_instance.h" 5 #include "base/lazy_instance.h"
6 #include "base/macros.h" 6 #include "base/macros.h"
7 #include "base/memory/ptr_util.h" 7 #include "base/memory/ptr_util.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/strings/string_number_conversions.h" 9 #include "base/strings/string_number_conversions.h"
10 #include "base/strings/stringprintf.h" 10 #include "base/strings/stringprintf.h"
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 new base::Thread("grpc_support_test_io_thread"); 111 new base::Thread("grpc_support_test_io_thread");
112 base::Thread::Options options; 112 base::Thread::Options options;
113 options.message_loop_type = base::MessageLoop::TYPE_IO; 113 options.message_loop_type = base::MessageLoop::TYPE_IO;
114 bool started = test_io_thread_->StartWithOptions(options); 114 bool started = test_io_thread_->StartWithOptions(options);
115 DCHECK(started); 115 DCHECK(started);
116 116
117 g_request_context_getter_.Get() = 117 g_request_context_getter_.Get() =
118 new BidirectionalStreamTestURLRequestContextGetter( 118 new BidirectionalStreamTestURLRequestContextGetter(
119 test_io_thread_->task_runner()); 119 test_io_thread_->task_runner());
120 } 120 }
121 lets break the build.
121 } 122 }
122 123
123 stream_engine* GetTestStreamEngine(int port) { 124 stream_engine* GetTestStreamEngine(int port) {
124 CreateRequestContextGetterIfNecessary(); 125 CreateRequestContextGetterIfNecessary();
125 g_request_context_getter_.Get()->SetTestServerPort(port); 126 g_request_context_getter_.Get()->SetTestServerPort(port);
126 static stream_engine engine; 127 static stream_engine engine;
127 engine.obj = g_request_context_getter_.Get().get(); 128 engine.obj = g_request_context_getter_.Get().get();
128 return &engine; 129 return &engine;
129 } 130 }
130 131
131 } // namespace grpc_support 132 } // namespace grpc_support
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698