OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <string> | 5 #include <string> |
6 | 6 |
7 #include "base/message_loop/message_loop.h" | 7 #include "base/message_loop/message_loop.h" |
8 #include "base/prefs/pref_service.h" | 8 #include "base/prefs/pref_service.h" |
9 #include "base/strings/stringprintf.h" | 9 #include "base/strings/stringprintf.h" |
10 #include "base/synchronization/waitable_event.h" | 10 #include "base/synchronization/waitable_event.h" |
(...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
446 // These should be cookie values that we generated by calling /MergeSession, | 446 // These should be cookie values that we generated by calling /MergeSession, |
447 // since /ListAccounts should have tell us that the initial session cookies | 447 // since /ListAccounts should have tell us that the initial session cookies |
448 // are stale. | 448 // are stale. |
449 EXPECT_EQ(cookie_reader->GetCookieValue("SID"), kTestSession2SIDCookie); | 449 EXPECT_EQ(cookie_reader->GetCookieValue("SID"), kTestSession2SIDCookie); |
450 EXPECT_EQ(cookie_reader->GetCookieValue("LSID"), kTestSession2LSIDCookie); | 450 EXPECT_EQ(cookie_reader->GetCookieValue("LSID"), kTestSession2LSIDCookie); |
451 } | 451 } |
452 | 452 |
453 // MergeSession test is attempting to merge session for an existing profile | 453 // MergeSession test is attempting to merge session for an existing profile |
454 // that was generated in PRE_PRE_MergeSession test. This attempt should fail | 454 // that was generated in PRE_PRE_MergeSession test. This attempt should fail |
455 // since FakeGaia instance isn't configured to return relevant tokens/cookies. | 455 // since FakeGaia instance isn't configured to return relevant tokens/cookies. |
456 IN_PROC_BROWSER_TEST_F(OAuth2Test, MergeSession) { | 456 // This test is flaky, see: crbug.com/408867. |
| 457 IN_PROC_BROWSER_TEST_F(OAuth2Test, DISABLED_MergeSession) { |
457 SimulateNetworkOnline(); | 458 SimulateNetworkOnline(); |
458 | 459 |
459 content::WindowedNotificationObserver( | 460 content::WindowedNotificationObserver( |
460 chrome::NOTIFICATION_LOGIN_OR_LOCK_WEBUI_VISIBLE, | 461 chrome::NOTIFICATION_LOGIN_OR_LOCK_WEBUI_VISIBLE, |
461 content::NotificationService::AllSources()).Wait(); | 462 content::NotificationService::AllSources()).Wait(); |
462 | 463 |
463 JsExpect("!!document.querySelector('#account-picker')"); | 464 JsExpect("!!document.querySelector('#account-picker')"); |
464 JsExpect("!!document.querySelector('#pod-row')"); | 465 JsExpect("!!document.querySelector('#pod-row')"); |
465 | 466 |
466 EXPECT_EQ(GetOAuthStatusFromLocalState(kTestAccountId), | 467 EXPECT_EQ(GetOAuthStatusFromLocalState(kTestAccountId), |
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
780 | 781 |
781 if (!catcher.GetNextResult()) { | 782 if (!catcher.GetNextResult()) { |
782 std::string message = catcher.message(); | 783 std::string message = catcher.message(); |
783 ADD_FAILURE() << "Tests failed: " << message; | 784 ADD_FAILURE() << "Tests failed: " << message; |
784 } | 785 } |
785 | 786 |
786 EXPECT_TRUE(fake_google_.IsPageRequested()); | 787 EXPECT_TRUE(fake_google_.IsPageRequested()); |
787 } | 788 } |
788 | 789 |
789 } // namespace chromeos | 790 } // namespace chromeos |
OLD | NEW |