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

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

Issue 397243004: Pepper: Remove trusted plugin loadable module. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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
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 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 } 201 }
202 202
203 NaClBrowserTestBase::~NaClBrowserTestBase() { 203 NaClBrowserTestBase::~NaClBrowserTestBase() {
204 } 204 }
205 205
206 void NaClBrowserTestBase::SetUpCommandLine(base::CommandLine* command_line) { 206 void NaClBrowserTestBase::SetUpCommandLine(base::CommandLine* command_line) {
207 command_line->AppendSwitch(switches::kEnableNaCl); 207 command_line->AppendSwitch(switches::kEnableNaCl);
208 } 208 }
209 209
210 void NaClBrowserTestBase::SetUpOnMainThread() { 210 void NaClBrowserTestBase::SetUpOnMainThread() {
211 // Sanity check.
212 base::FilePath plugin_lib;
213 ASSERT_TRUE(PathService::Get(chrome::FILE_NACL_PLUGIN, &plugin_lib));
214 ASSERT_TRUE(base::PathExists(plugin_lib)) << plugin_lib.value();
215
216 ASSERT_TRUE(StartTestServer()) << "Cannot start test server."; 211 ASSERT_TRUE(StartTestServer()) << "Cannot start test server.";
217 } 212 }
218 213
219 bool NaClBrowserTestBase::GetDocumentRoot(base::FilePath* document_root) { 214 bool NaClBrowserTestBase::GetDocumentRoot(base::FilePath* document_root) {
220 return GetNaClVariantRoot(Variant(), document_root); 215 return GetNaClVariantRoot(Variant(), document_root);
221 } 216 }
222 217
223 bool NaClBrowserTestBase::IsAPnaclTest() { 218 bool NaClBrowserTestBase::IsAPnaclTest() {
224 return false; 219 return false;
225 } 220 }
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 // to point at the isolated the test extension directory. 359 // to point at the isolated the test extension directory.
365 // Otherwise, multiple NaCl extensions tests will end up sharing the 360 // Otherwise, multiple NaCl extensions tests will end up sharing the
366 // same directory when loading the extension files. 361 // same directory when loading the extension files.
367 base::FilePath document_root; 362 base::FilePath document_root;
368 ASSERT_TRUE(GetDocumentRoot(&document_root)); 363 ASSERT_TRUE(GetDocumentRoot(&document_root));
369 364
370 // Document root is relative to source root, and source root may not be CWD. 365 // Document root is relative to source root, and source root may not be CWD.
371 command_line->AppendSwitchPath(switches::kLoadExtension, 366 command_line->AppendSwitchPath(switches::kLoadExtension,
372 src_root.Append(document_root)); 367 src_root.Append(document_root));
373 } 368 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698