Chromium Code Reviews| Index: chrome/browser/ui/login/login_prompt_browsertest.cc |
| diff --git a/chrome/browser/ui/login/login_prompt_browsertest.cc b/chrome/browser/ui/login/login_prompt_browsertest.cc |
| index de9be6f44ab2725d098d5754fd6ee88bceaf1c0c..e8862ea3986abbd113f43827133a807ce54d5162 100644 |
| --- a/chrome/browser/ui/login/login_prompt_browsertest.cc |
| +++ b/chrome/browser/ui/login/login_prompt_browsertest.cc |
| @@ -276,7 +276,8 @@ IN_PROC_BROWSER_TEST_F(LoginPromptBrowserTest, MultipleRealmConfirmation) { |
| // Testing for recovery from an incorrect password for the case where |
| // there are multiple authenticated resources. |
| -// Marked as flaky. See crbug.com/68860 |
| +// Marked as flaky. See crbug.com/69266 and http://crbug.com/68860 |
|
cbentzel
2011/01/12 15:04:25
Nit: use full URL for 69266.
|
| +// TODO(asanka): Remove logging when timeout issues are resolved. |
| IN_PROC_BROWSER_TEST_F(LoginPromptBrowserTest, FLAKY_IncorrectConfirmation) { |
| ASSERT_TRUE(test_server()->Start()); |
| GURL test_page = test_server()->GetURL(kSingleRealmTestPage); |
| @@ -292,9 +293,11 @@ IN_PROC_BROWSER_TEST_F(LoginPromptBrowserTest, FLAKY_IncorrectConfirmation) { |
| WindowedLoadStopObserver load_stop_waiter(controller); |
| + LOG(INFO) << "Begin"; |
| { |
| WindowedAuthNeededObserver auth_needed_waiter(controller); |
| browser()->OpenURL(test_page, GURL(), CURRENT_TAB, PageTransition::TYPED); |
| + LOG(INFO) << "Waiting for initial AUTH_NEEDED"; |
| auth_needed_waiter.Wait(); |
| } |
| @@ -307,11 +310,13 @@ IN_PROC_BROWSER_TEST_F(LoginPromptBrowserTest, FLAKY_IncorrectConfirmation) { |
| ASSERT_TRUE(handler); |
| handler->SetAuth(bad_username_, bad_password_); |
| + LOG(INFO) << "Waiting for initial AUTH_SUPPLIED"; |
| auth_supplied_waiter.Wait(); |
| // The request should be retried after the incorrect password is |
| // supplied. This should result in a new AUTH_NEEDED notification |
| // for the same realm. |
| + LOG(INFO) << "Waiting for secondary AUTH_NEEDED"; |
| auth_needed_waiter.Wait(); |
| } |
| @@ -327,21 +332,26 @@ IN_PROC_BROWSER_TEST_F(LoginPromptBrowserTest, FLAKY_IncorrectConfirmation) { |
| ASSERT_TRUE(handler); |
| n_handlers++; |
| SetAuthFor(handler); |
| + LOG(INFO) << "Waiting for secondary AUTH_SUPPLIED"; |
| auth_supplied_waiter.Wait(); |
| } |
| - if (n_handlers < 1) |
| + if (n_handlers < 1) { |
| + LOG(INFO) << "Waiting for additional AUTH_NEEDED"; |
| auth_needed_waiter.Wait(); |
| + } |
| } |
| + LOG(INFO) << "Waiting for LOAD_STOP"; |
| load_stop_waiter.Wait(); |
| // The single realm test has only one realm, and thus only one login |
| // prompt. |
| EXPECT_EQ(1, n_handlers); |
| EXPECT_LT(0, observer.auth_needed_count_); |
| - EXPECT_LT(0, observer.auth_supplied_count_); |
| EXPECT_EQ(0, observer.auth_cancelled_count_); |
| + EXPECT_EQ(observer.auth_needed_count_, observer.auth_supplied_count_); |
|
cbentzel
2011/01/11 19:40:34
Was this added for a stronger test?
asanka
2011/01/11 21:58:05
Yeah. With the current state of the code, we shou
|
| EXPECT_TRUE(test_server()->Stop()); |
| + LOG(INFO) << "Done"; |
| } |
| -} // namespace |
| +} // namespace |