OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 <stddef.h> | 5 #include <stddef.h> |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/run_loop.h" | 12 #include "base/run_loop.h" |
| 13 #include "chrome/browser/chrome_notification_types.h" |
13 #include "chrome/browser/extensions/browser_action_test_util.h" | 14 #include "chrome/browser/extensions/browser_action_test_util.h" |
14 #include "chrome/browser/extensions/extension_browsertest.h" | 15 #include "chrome/browser/extensions/extension_browsertest.h" |
15 #include "chrome/browser/extensions/extension_service.h" | 16 #include "chrome/browser/extensions/extension_service.h" |
16 #include "chrome/browser/extensions/test_extension_dir.h" | 17 #include "chrome/browser/extensions/test_extension_dir.h" |
17 #include "chrome/browser/ui/tabs/tab_strip_model.h" | 18 #include "chrome/browser/ui/tabs/tab_strip_model.h" |
18 #include "chrome/common/extensions/extension_process_policy.h" | 19 #include "chrome/common/extensions/extension_process_policy.h" |
19 #include "chrome/common/pref_names.h" | 20 #include "chrome/common/pref_names.h" |
20 #include "chrome/test/base/in_process_browser_test.h" | 21 #include "chrome/test/base/in_process_browser_test.h" |
21 #include "chrome/test/base/ui_test_utils.h" | 22 #include "chrome/test/base/ui_test_utils.h" |
22 #include "content/public/browser/child_process_security_policy.h" | 23 #include "content/public/browser/child_process_security_policy.h" |
(...skipping 930 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
953 EXPECT_TRUE(ExecuteScriptAndExtractBool( | 954 EXPECT_TRUE(ExecuteScriptAndExtractBool( |
954 popup, "window.domAutomationController.send(!!window.opener)", | 955 popup, "window.domAutomationController.send(!!window.opener)", |
955 &is_opener_defined)); | 956 &is_opener_defined)); |
956 EXPECT_TRUE(is_opener_defined); | 957 EXPECT_TRUE(is_opener_defined); |
957 | 958 |
958 // Verify that postMessage to window.opener works. | 959 // Verify that postMessage to window.opener works. |
959 VerifyPostMessageToOpener(popup->GetMainFrame(), extension_frame); | 960 VerifyPostMessageToOpener(popup->GetMainFrame(), extension_frame); |
960 } | 961 } |
961 | 962 |
962 } // namespace extensions | 963 } // namespace extensions |
OLD | NEW |