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

Side by Side Diff: content/browser/webui/web_ui_mojo_browsertest.cc

Issue 213313004: Add creation of ServiceManager to Content (2nd try) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add shell_client to mojo_pepper_container_app Created 6 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 | Annotate | Revision Log
« no previous file with comments | « content/app/mojo/mojo_init.cc ('k') | content/common/mojo/mojo_channel_init.h » ('j') | 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 #include "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/file_util.h" 6 #include "base/file_util.h"
7 #include "base/files/file_path.h" 7 #include "base/files/file_path.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "base/strings/string_util.h" 10 #include "base/strings/string_util.h"
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 142
143 private: 143 private:
144 base::RunLoop* run_loop_; 144 base::RunLoop* run_loop_;
145 145
146 DISALLOW_COPY_AND_ASSIGN(TestWebUIControllerFactory); 146 DISALLOW_COPY_AND_ASSIGN(TestWebUIControllerFactory);
147 }; 147 };
148 148
149 class WebUIMojoTest : public ContentBrowserTest { 149 class WebUIMojoTest : public ContentBrowserTest {
150 public: 150 public:
151 WebUIMojoTest() { 151 WebUIMojoTest() {
152 MojoChannelInit::InitMojo();
153 WebUIControllerFactory::RegisterFactory(&factory_); 152 WebUIControllerFactory::RegisterFactory(&factory_);
154 } 153 }
155 154
156 virtual ~WebUIMojoTest() { 155 virtual ~WebUIMojoTest() {
157 WebUIControllerFactory::UnregisterFactoryForTesting(&factory_); 156 WebUIControllerFactory::UnregisterFactoryForTesting(&factory_);
158 } 157 }
159 158
160 TestWebUIControllerFactory* factory() { return &factory_; } 159 TestWebUIControllerFactory* factory() { return &factory_; }
161 160
162 private: 161 private:
(...skipping 23 matching lines...) Expand all
186 factory()->set_run_loop(&run_loop); 185 factory()->set_run_loop(&run_loop);
187 GURL test_url(test_server()->GetURL("files/web_ui_mojo.html")); 186 GURL test_url(test_server()->GetURL("files/web_ui_mojo.html"));
188 NavigateToURL(shell(), test_url); 187 NavigateToURL(shell(), test_url);
189 // RunLoop is quit when message received from page. 188 // RunLoop is quit when message received from page.
190 run_loop.Run(); 189 run_loop.Run();
191 EXPECT_TRUE(got_message); 190 EXPECT_TRUE(got_message);
192 } 191 }
193 192
194 } // namespace 193 } // namespace
195 } // namespace content 194 } // namespace content
OLDNEW
« no previous file with comments | « content/app/mojo/mojo_init.cc ('k') | content/common/mojo/mojo_channel_init.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698