| OLD | NEW |
| 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/environment.h" | 9 #include "base/environment.h" |
| 10 #include "base/json/json_reader.h" | 10 #include "base/json/json_reader.h" |
| (...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 187 } | 187 } |
| 188 } | 188 } |
| 189 | 189 |
| 190 NaClBrowserTestBase::NaClBrowserTestBase() { | 190 NaClBrowserTestBase::NaClBrowserTestBase() { |
| 191 } | 191 } |
| 192 | 192 |
| 193 NaClBrowserTestBase::~NaClBrowserTestBase() { | 193 NaClBrowserTestBase::~NaClBrowserTestBase() { |
| 194 } | 194 } |
| 195 | 195 |
| 196 void NaClBrowserTestBase::SetUpCommandLine(CommandLine* command_line) { | 196 void NaClBrowserTestBase::SetUpCommandLine(CommandLine* command_line) { |
| 197 command_line->AppendSwitch(switches::kNoFirstRun); | |
| 198 command_line->AppendSwitch(switches::kEnableNaCl); | 197 command_line->AppendSwitch(switches::kEnableNaCl); |
| 199 } | 198 } |
| 200 | 199 |
| 201 void NaClBrowserTestBase::SetUpInProcessBrowserTestFixture() { | 200 void NaClBrowserTestBase::SetUpInProcessBrowserTestFixture() { |
| 202 // Sanity check. | 201 // Sanity check. |
| 203 base::FilePath plugin_lib; | 202 base::FilePath plugin_lib; |
| 204 ASSERT_TRUE(PathService::Get(chrome::FILE_NACL_PLUGIN, &plugin_lib)); | 203 ASSERT_TRUE(PathService::Get(chrome::FILE_NACL_PLUGIN, &plugin_lib)); |
| 205 ASSERT_TRUE(base::PathExists(plugin_lib)) << plugin_lib.value(); | 204 ASSERT_TRUE(base::PathExists(plugin_lib)) << plugin_lib.value(); |
| 206 | 205 |
| 207 ASSERT_TRUE(StartTestServer()) << "Cannot start test server."; | 206 ASSERT_TRUE(StartTestServer()) << "Cannot start test server."; |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 294 } | 293 } |
| 295 | 294 |
| 296 base::FilePath::StringType NaClBrowserTestStatic::Variant() { | 295 base::FilePath::StringType NaClBrowserTestStatic::Variant() { |
| 297 return FILE_PATH_LITERAL("static"); | 296 return FILE_PATH_LITERAL("static"); |
| 298 } | 297 } |
| 299 | 298 |
| 300 bool NaClBrowserTestStatic::GetDocumentRoot(base::FilePath* document_root) { | 299 bool NaClBrowserTestStatic::GetDocumentRoot(base::FilePath* document_root) { |
| 301 *document_root = base::FilePath(FILE_PATH_LITERAL("chrome/test/data/nacl")); | 300 *document_root = base::FilePath(FILE_PATH_LITERAL("chrome/test/data/nacl")); |
| 302 return true; | 301 return true; |
| 303 } | 302 } |
| OLD | NEW |