Re-enable CrashRecoveryBrowserTest.* with additional logging

to help with debugging flakiness issues.

BUG=29331, 57158, 69637
TEST=browser_tests
Review URL: http://codereview.chromium.org/6246006

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@71673 0039d316-1c4b-4281-b951-d872f2087c98
parent ce04cfd0
......@@ -17,8 +17,10 @@ namespace {
void SimulateRendererCrash(Browser* browser) {
browser->OpenURL(GURL(chrome::kAboutCrashURL), GURL(), CURRENT_TAB,
PageTransition::TYPED);
LOG(ERROR) << "SimulateRendererCrash, before WaitForNotification";
ui_test_utils::WaitForNotification(
NotificationType::TAB_CONTENTS_DISCONNECTED);
LOG(ERROR) << "SimulateRendererCrash, after WaitForNotification";
}
} // namespace
......@@ -28,7 +30,7 @@ class CrashRecoveryBrowserTest : public InProcessBrowserTest {
// Test that reload works after a crash.
// Disabled, http://crbug.com/29331, http://crbug.com/69637.
IN_PROC_BROWSER_TEST_F(CrashRecoveryBrowserTest, DISABLED_Reload) {
IN_PROC_BROWSER_TEST_F(CrashRecoveryBrowserTest, Reload) {
// The title of the active tab should change each time this URL is loaded.
GURL url(
"data:text/html,<script>document.title=new Date().valueOf()</script>");
......@@ -41,7 +43,9 @@ IN_PROC_BROWSER_TEST_F(CrashRecoveryBrowserTest, DISABLED_Reload) {
&title_before_crash));
SimulateRendererCrash(browser());
browser()->Reload(CURRENT_TAB);
LOG(ERROR) << "Before WaitForNavigationInCurrentTab";
ASSERT_TRUE(ui_test_utils::WaitForNavigationInCurrentTab(browser()));
LOG(ERROR) << "After WaitForNavigationInCurrentTab";
ASSERT_TRUE(ui_test_utils::GetCurrentTabTitle(browser(),
&title_after_crash));
EXPECT_NE(title_before_crash, title_after_crash);
......@@ -52,7 +56,7 @@ IN_PROC_BROWSER_TEST_F(CrashRecoveryBrowserTest, DISABLED_Reload) {
// ID of the RenderProcessHost was stale, so the NavigationEntry in the new tab
// was not committed. This prevents regression of that bug.
// http://crbug.com/57158 - Times out sometimes on all platforms.
IN_PROC_BROWSER_TEST_F(CrashRecoveryBrowserTest, DISABLED_LoadInNewTab) {
IN_PROC_BROWSER_TEST_F(CrashRecoveryBrowserTest, LoadInNewTab) {
const FilePath::CharType* kTitle2File = FILE_PATH_LITERAL("title2.html");
ui_test_utils::NavigateToURL(browser(),
......@@ -66,7 +70,9 @@ IN_PROC_BROWSER_TEST_F(CrashRecoveryBrowserTest, DISABLED_LoadInNewTab) {
&title_before_crash));
SimulateRendererCrash(browser());
browser()->Reload(CURRENT_TAB);
LOG(ERROR) << "Before WaitForNavigationInCurrentTab";
ASSERT_TRUE(ui_test_utils::WaitForNavigationInCurrentTab(browser()));
LOG(ERROR) << "After WaitForNavigationInCurrentTab";
ASSERT_TRUE(ui_test_utils::GetCurrentTabTitle(browser(),
&title_after_crash));
EXPECT_EQ(title_before_crash, title_after_crash);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment