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

Side by Side Diff: chrome/test/nacl/nacl_browsertest_util.cc

Issue 190663012: Run ContentMain in a browser_test's browser process. This removes duplication of code in the browse… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: try to fix android by restoring old path just for it 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 | « chrome/test/nacl/nacl_browsertest_util.h ('k') | chrome/test/ppapi/ppapi_test.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/test/nacl/nacl_browsertest_util.h" 5 #include "chrome/test/nacl/nacl_browsertest_util.h"
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/json/json_reader.h" 9 #include "base/json/json_reader.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
198 NaClBrowserTestBase::NaClBrowserTestBase() { 198 NaClBrowserTestBase::NaClBrowserTestBase() {
199 } 199 }
200 200
201 NaClBrowserTestBase::~NaClBrowserTestBase() { 201 NaClBrowserTestBase::~NaClBrowserTestBase() {
202 } 202 }
203 203
204 void NaClBrowserTestBase::SetUpCommandLine(CommandLine* command_line) { 204 void NaClBrowserTestBase::SetUpCommandLine(CommandLine* command_line) {
205 command_line->AppendSwitch(switches::kEnableNaCl); 205 command_line->AppendSwitch(switches::kEnableNaCl);
206 } 206 }
207 207
208 void NaClBrowserTestBase::SetUpInProcessBrowserTestFixture() { 208 void NaClBrowserTestBase::SetUpOnMainThread() {
209 // Sanity check. 209 // Sanity check.
210 base::FilePath plugin_lib; 210 base::FilePath plugin_lib;
211 ASSERT_TRUE(PathService::Get(chrome::FILE_NACL_PLUGIN, &plugin_lib)); 211 ASSERT_TRUE(PathService::Get(chrome::FILE_NACL_PLUGIN, &plugin_lib));
212 ASSERT_TRUE(base::PathExists(plugin_lib)) << plugin_lib.value(); 212 ASSERT_TRUE(base::PathExists(plugin_lib)) << plugin_lib.value();
213 213
214 ASSERT_TRUE(StartTestServer()) << "Cannot start test server."; 214 ASSERT_TRUE(StartTestServer()) << "Cannot start test server.";
215 } 215 }
216 216
217 bool NaClBrowserTestBase::GetDocumentRoot(base::FilePath* document_root) { 217 bool NaClBrowserTestBase::GetDocumentRoot(base::FilePath* document_root) {
218 return GetNaClVariantRoot(Variant(), document_root); 218 return GetNaClVariantRoot(Variant(), document_root);
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
319 } 319 }
320 320
321 base::FilePath::StringType NaClBrowserTestStatic::Variant() { 321 base::FilePath::StringType NaClBrowserTestStatic::Variant() {
322 return FILE_PATH_LITERAL("static"); 322 return FILE_PATH_LITERAL("static");
323 } 323 }
324 324
325 bool NaClBrowserTestStatic::GetDocumentRoot(base::FilePath* document_root) { 325 bool NaClBrowserTestStatic::GetDocumentRoot(base::FilePath* document_root) {
326 *document_root = base::FilePath(FILE_PATH_LITERAL("chrome/test/data/nacl")); 326 *document_root = base::FilePath(FILE_PATH_LITERAL("chrome/test/data/nacl"));
327 return true; 327 return true;
328 } 328 }
OLDNEW
« no previous file with comments | « chrome/test/nacl/nacl_browsertest_util.h ('k') | chrome/test/ppapi/ppapi_test.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698