| 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 // windows headers | 5 // windows headers |
| 6 #include <windows.h> | 6 #include <windows.h> |
| 7 #include <shellapi.h> | 7 #include <shellapi.h> |
| 8 #include <shlobj.h> | 8 #include <shlobj.h> |
| 9 #include <atlbase.h> | 9 #include <atlbase.h> |
| 10 #include <comutil.h> | 10 #include <comutil.h> |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 | 129 |
| 130 // Tests if a plugin executing a self deleting script using Invoke with | 130 // Tests if a plugin executing a self deleting script using Invoke with |
| 131 // a modal dialog showing works without crashing or hanging | 131 // a modal dialog showing works without crashing or hanging |
| 132 TEST_F(NPAPITester, DISABLED_SelfDeletePluginInvokeAlert) { | 132 TEST_F(NPAPITester, DISABLED_SelfDeletePluginInvokeAlert) { |
| 133 std::wstring test_case = L"self_delete_plugin_invoke_alert.html"; | 133 std::wstring test_case = L"self_delete_plugin_invoke_alert.html"; |
| 134 GURL url = GetTestUrl(L"npapi", test_case); | 134 GURL url = GetTestUrl(L"npapi", test_case); |
| 135 NavigateToURL(url); | 135 NavigateToURL(url); |
| 136 | 136 |
| 137 // Wait for the alert dialog and then close it. | 137 // Wait for the alert dialog and then close it. |
| 138 automation()->WaitForAppModalDialog(5000); | 138 automation()->WaitForAppModalDialog(5000); |
| 139 scoped_ptr<WindowProxy> window(automation()->GetActiveWindow()); | 139 scoped_refptr<WindowProxy> window(automation()->GetActiveWindow()); |
| 140 ASSERT_TRUE(window.get()); | 140 ASSERT_TRUE(window.get()); |
| 141 ASSERT_TRUE(window->SimulateOSKeyPress(VK_ESCAPE, 0)); | 141 ASSERT_TRUE(window->SimulateOSKeyPress(VK_ESCAPE, 0)); |
| 142 | 142 |
| 143 WaitForFinish("self_delete_plugin_invoke_alert", "1", url, | 143 WaitForFinish("self_delete_plugin_invoke_alert", "1", url, |
| 144 kTestCompleteCookie, kTestCompleteSuccess, | 144 kTestCompleteCookie, kTestCompleteSuccess, |
| 145 kShortWaitTimeout); | 145 kShortWaitTimeout); |
| 146 } | 146 } |
| 147 | 147 |
| 148 // Tests if a plugin executing a self deleting script in the context of | 148 // Tests if a plugin executing a self deleting script in the context of |
| 149 // a synchronous paint event works correctly | 149 // a synchronous paint event works correctly |
| (...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 277 // Test checking the privacy mode is on. | 277 // Test checking the privacy mode is on. |
| 278 TEST_F(NPAPIIncognitoTester, PrivateEnabled) { | 278 TEST_F(NPAPIIncognitoTester, PrivateEnabled) { |
| 279 if (UITest::in_process_renderer()) | 279 if (UITest::in_process_renderer()) |
| 280 return; | 280 return; |
| 281 | 281 |
| 282 GURL url = GetTestUrl(L"npapi", L"private.html?secure"); | 282 GURL url = GetTestUrl(L"npapi", L"private.html?secure"); |
| 283 NavigateToURL(url); | 283 NavigateToURL(url); |
| 284 WaitForFinish("private", "1", url, kTestCompleteCookie, | 284 WaitForFinish("private", "1", url, kTestCompleteCookie, |
| 285 kTestCompleteSuccess, kShortWaitTimeout); | 285 kTestCompleteSuccess, kShortWaitTimeout); |
| 286 } | 286 } |
| OLD | NEW |