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 "ppapi/tests/test_broker.h" | 5 #include "ppapi/tests/test_broker.h" |
6 | 6 |
7 #if defined(_MSC_VER) | 7 #if defined(_MSC_VER) |
8 #define OS_WIN 1 | 8 #define OS_WIN 1 |
9 #include <windows.h> | 9 #include <windows.h> |
10 #else | 10 #else |
11 #define OS_POSIX 1 | 11 #define OS_POSIX 1 |
12 #include <errno.h> | 12 #include <errno.h> |
| 13 #include <unistd.h> |
13 #endif | 14 #endif |
14 | 15 |
15 #include <cstdio> | 16 #include <cstdio> |
16 #include <cstring> | 17 #include <cstring> |
17 #include <fstream> | 18 #include <fstream> |
18 #include <limits> | 19 #include <limits> |
19 | 20 |
20 #include "ppapi/c/pp_errors.h" | 21 #include "ppapi/c/pp_errors.h" |
21 #include "ppapi/c/trusted/ppp_broker.h" | 22 #include "ppapi/c/trusted/ppp_broker.h" |
22 #include "ppapi/c/trusted/ppb_broker_trusted.h" | 23 #include "ppapi/c/trusted/ppb_broker_trusted.h" |
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
279 | 280 |
280 PlatformFile file = IntToPlatformFile(handle); | 281 PlatformFile file = IntToPlatformFile(handle); |
281 ASSERT_TRUE(VerifyMessage(file, sizeof(kHelloMessage), kHelloMessage)); | 282 ASSERT_TRUE(VerifyMessage(file, sizeof(kHelloMessage), kHelloMessage)); |
282 ASSERT_TRUE(VerifyMessage(file, sizeof(kBrokerUnsandboxed), | 283 ASSERT_TRUE(VerifyMessage(file, sizeof(kBrokerUnsandboxed), |
283 kBrokerUnsandboxed)); | 284 kBrokerUnsandboxed)); |
284 | 285 |
285 ASSERT_TRUE(ClosePlatformFile(file)); | 286 ASSERT_TRUE(ClosePlatformFile(file)); |
286 | 287 |
287 PASS(); | 288 PASS(); |
288 } | 289 } |
OLD | NEW |