OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 #import <Foundation/Foundation.h> | 5 #import <Foundation/Foundation.h> |
6 #import <IOSurface/IOSurface.h> | 6 #import <IOSurface/IOSurface.h> |
7 | 7 |
8 #include <fcntl.h> | 8 #include <fcntl.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 #include <sys/mman.h> | 10 #include <sys/mman.h> |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
119 char oldp[oldp_len]; | 119 char oldp[oldp_len]; |
120 EXPECT_EQ(0, sysctlbyname("hw.activecpu", oldp, &oldp_len, NULL, 0)); | 120 EXPECT_EQ(0, sysctlbyname("hw.activecpu", oldp, &oldp_len, NULL, 0)); |
121 | 121 |
122 size_t ncpu_len; | 122 size_t ncpu_len; |
123 EXPECT_NE(0, sysctlbyname("hw.ncpu", NULL, &ncpu_len, NULL, 0)); | 123 EXPECT_NE(0, sysctlbyname("hw.ncpu", NULL, &ncpu_len, NULL, 0)); |
124 | 124 |
125 return 0; | 125 return 0; |
126 } | 126 } |
127 | 127 |
128 TEST_F(SandboxMacCompilerV2Test, V2ProfileTest) { | 128 TEST_F(SandboxMacCompilerV2Test, V2ProfileTest) { |
129 base::Process process = SpawnChild("V2ProfileProcess"); | 129 base::SpawnChildResult spawn_child = SpawnChild("V2ProfileProcess"); |
130 ASSERT_TRUE(process.IsValid()); | 130 ASSERT_TRUE(spawn_child.process.IsValid()); |
131 int exit_code = 42; | 131 int exit_code = 42; |
132 EXPECT_TRUE(process.WaitForExitWithTimeout(TestTimeouts::action_max_timeout(), | 132 EXPECT_TRUE(spawn_child.process.WaitForExitWithTimeout( |
133 &exit_code)); | 133 TestTimeouts::action_max_timeout(), &exit_code)); |
134 EXPECT_EQ(exit_code, 0); | 134 EXPECT_EQ(exit_code, 0); |
135 } | 135 } |
136 | 136 |
137 } // namespace sandbox | 137 } // namespace sandbox |
OLD | NEW |