| 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 <queue> | 5 #include <queue> |
| 6 #include <set> | 6 #include <set> |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/callback_helpers.h" | 9 #include "base/callback_helpers.h" |
| 10 #include "base/files/file_util.h" | 10 #include "base/files/file_util.h" |
| (...skipping 1522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1533 IN_PROC_BROWSER_TEST_P(WebViewTest, InterstitialTeardown) { | 1533 IN_PROC_BROWSER_TEST_P(WebViewTest, InterstitialTeardown) { |
| 1534 InterstitialTeardownTestHelper(); | 1534 InterstitialTeardownTestHelper(); |
| 1535 | 1535 |
| 1536 // Now close the app while interstitial page being shown in guest. | 1536 // Now close the app while interstitial page being shown in guest. |
| 1537 extensions::AppWindow* window = GetFirstAppWindow(); | 1537 extensions::AppWindow* window = GetFirstAppWindow(); |
| 1538 window->GetBaseWindow()->Close(); | 1538 window->GetBaseWindow()->Close(); |
| 1539 } | 1539 } |
| 1540 | 1540 |
| 1541 // This test makes sure the browser process does not crash if browser is shut | 1541 // This test makes sure the browser process does not crash if browser is shut |
| 1542 // down while an interstitial page is being shown in guest. | 1542 // down while an interstitial page is being shown in guest. |
| 1543 IN_PROC_BROWSER_TEST_P(WebViewTest, InterstitialTeardownOnBrowserShutdown) { | 1543 // Flaky on Windows. http://crbug.com/619508. |
| 1544 #if defined(OS_WIN) |
| 1545 #define MAYBE_InterstitialTeardownOnBrowserShutdown \ |
| 1546 DISABLED_InterstitialTeardownOnBrowserShutdown |
| 1547 #else |
| 1548 #define MAYBE_InterstitialTeardownOnBrowserShutdown \ |
| 1549 InterstitialTeardownOnBrowserShutdown |
| 1550 #endif |
| 1551 IN_PROC_BROWSER_TEST_P(WebViewTest, |
| 1552 MAYBE_InterstitialTeardownOnBrowserShutdown) { |
| 1544 InterstitialTeardownTestHelper(); | 1553 InterstitialTeardownTestHelper(); |
| 1545 | 1554 |
| 1546 // Now close the app while interstitial page being shown in guest. | 1555 // Now close the app while interstitial page being shown in guest. |
| 1547 extensions::AppWindow* window = GetFirstAppWindow(); | 1556 extensions::AppWindow* window = GetFirstAppWindow(); |
| 1548 window->GetBaseWindow()->Close(); | 1557 window->GetBaseWindow()->Close(); |
| 1549 | 1558 |
| 1550 // InterstitialPage is not destroyed immediately, so the | 1559 // InterstitialPage is not destroyed immediately, so the |
| 1551 // RenderWidgetHostViewGuest for it is still there, closing all | 1560 // RenderWidgetHostViewGuest for it is still there, closing all |
| 1552 // renderer processes will cause the RWHVGuest's RenderProcessGone() | 1561 // renderer processes will cause the RWHVGuest's RenderProcessGone() |
| 1553 // shutdown path to be exercised. | 1562 // shutdown path to be exercised. |
| (...skipping 2033 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3587 gfx::Point embedder_origin = | 3596 gfx::Point embedder_origin = |
| 3588 GetEmbedderWebContents()->GetContainerBounds().origin(); | 3597 GetEmbedderWebContents()->GetContainerBounds().origin(); |
| 3589 guest_rect.Offset(-embedder_origin.x(), -embedder_origin.y()); | 3598 guest_rect.Offset(-embedder_origin.x(), -embedder_origin.y()); |
| 3590 | 3599 |
| 3591 // Generate and send synthetic touch event. | 3600 // Generate and send synthetic touch event. |
| 3592 content::SimulateTouchPressAt(GetEmbedderWebContents(), | 3601 content::SimulateTouchPressAt(GetEmbedderWebContents(), |
| 3593 guest_rect.CenterPoint()); | 3602 guest_rect.CenterPoint()); |
| 3594 EXPECT_TRUE(aura_webview->HasFocus()); | 3603 EXPECT_TRUE(aura_webview->HasFocus()); |
| 3595 } | 3604 } |
| 3596 #endif | 3605 #endif |
| OLD | NEW |