OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_test.h" | 5 #include "chrome/test/nacl/nacl_test.h" |
6 | 6 |
7 #include "base/file_util.h" | 7 #include "base/file_util.h" |
8 #include "base/path_service.h" | 8 #include "base/path_service.h" |
9 #include "chrome/common/chrome_paths.h" | 9 #include "chrome/common/chrome_paths.h" |
10 #include "chrome/common/chrome_switches.h" | 10 #include "chrome/common/chrome_switches.h" |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
55 | 55 |
56 } // anonymous namespace | 56 } // anonymous namespace |
57 | 57 |
58 NaClTest::NaClTest() | 58 NaClTest::NaClTest() |
59 : UITest() { | 59 : UITest() { |
60 launch_arguments_.AppendSwitch(switches::kEnableNaCl); | 60 launch_arguments_.AppendSwitch(switches::kEnableNaCl); |
61 | 61 |
62 // Currently we disable some of the sandboxes. See: | 62 // Currently we disable some of the sandboxes. See: |
63 // Make NaCl work in Chromium's Linux seccomp sandbox and the Mac sandbox | 63 // Make NaCl work in Chromium's Linux seccomp sandbox and the Mac sandbox |
64 // http://code.google.com/p/nativeclient/issues/detail?id=344 | 64 // http://code.google.com/p/nativeclient/issues/detail?id=344 |
65 #if defined(OS_MACOSX) | 65 #if defined(OS_LINUX) && defined(USE_SECCOMP_SANDBOX) |
66 launch_arguments_.AppendSwitch(switches::kNoSandbox); | |
67 #elif defined(OS_LINUX) && defined(USE_SECCOMP_SANDBOX) | |
68 launch_arguments_.AppendSwitch(switches::kDisableSeccompSandbox); | 66 launch_arguments_.AppendSwitch(switches::kDisableSeccompSandbox); |
69 #endif | 67 #endif |
70 } | 68 } |
71 | 69 |
72 NaClTest::~NaClTest() {} | 70 NaClTest::~NaClTest() {} |
73 | 71 |
74 FilePath NaClTest::GetTestRootDir() { | 72 FilePath NaClTest::GetTestRootDir() { |
75 FilePath path; | 73 FilePath path; |
76 PathService::Get(base::DIR_SOURCE_ROOT, &path); | 74 PathService::Get(base::DIR_SOURCE_ROOT, &path); |
77 path = path.AppendASCII("native_client"); | 75 path = path.AppendASCII("native_client"); |
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
311 } | 309 } |
312 | 310 |
313 #if defined(OS_WIN) | 311 #if defined(OS_WIN) |
314 TEST_F(NaClTest, FLAKY_SrpcNrdXferTest) { | 312 TEST_F(NaClTest, FLAKY_SrpcNrdXferTest) { |
315 #else | 313 #else |
316 TEST_F(NaClTest, SrpcNrdXferTest) { | 314 TEST_F(NaClTest, SrpcNrdXferTest) { |
317 #endif | 315 #endif |
318 FilePath test_file(kSrpcNrdXferHtmlFileName); | 316 FilePath test_file(kSrpcNrdXferHtmlFileName); |
319 RunTest(test_file, NaClTestTimeout()); | 317 RunTest(test_file, NaClTestTimeout()); |
320 } | 318 } |
OLD | NEW |