OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <set> | 5 #include <set> |
6 #include <tuple> | 6 #include <tuple> |
7 | 7 |
8 #include "base/json/json_reader.h" | 8 #include "base/json/json_reader.h" |
| 9 #include "base/macros.h" |
9 #include "base/pickle.h" | 10 #include "base/pickle.h" |
10 #include "base/values.h" | 11 #include "base/values.h" |
11 #include "extensions/common/api/sockets/sockets_manifest_permission.h" | 12 #include "extensions/common/api/sockets/sockets_manifest_permission.h" |
12 #include "extensions/common/manifest_constants.h" | 13 #include "extensions/common/manifest_constants.h" |
13 #include "ipc/ipc_message.h" | 14 #include "ipc/ipc_message.h" |
14 #include "testing/gtest/include/gtest/gtest.h" | 15 #include "testing/gtest/include/gtest/gtest.h" |
15 | 16 |
16 using content::SocketPermissionRequest; | 17 using content::SocketPermissionRequest; |
17 | 18 |
18 namespace extensions { | 19 namespace extensions { |
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
397 new SocketsManifestPermission()); | 398 new SocketsManifestPermission()); |
398 | 399 |
399 IPC::Message m; | 400 IPC::Message m; |
400 ipc_perm->Write(&m); | 401 ipc_perm->Write(&m); |
401 base::PickleIterator iter(m); | 402 base::PickleIterator iter(m); |
402 EXPECT_TRUE(ipc_perm2->Read(&m, &iter)); | 403 EXPECT_TRUE(ipc_perm2->Read(&m, &iter)); |
403 EXPECT_TRUE(permission->Equal(ipc_perm2.get())); | 404 EXPECT_TRUE(permission->Equal(ipc_perm2.get())); |
404 } | 405 } |
405 | 406 |
406 } // namespace extensions | 407 } // namespace extensions |
OLD | NEW |