| 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 "base/bind.h" | 5 #include "base/bind.h" |
| 6 #include "base/bind_helpers.h" | 6 #include "base/bind_helpers.h" |
| 7 #include "base/callback.h" | 7 #include "base/callback.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/files/file_path.h" | 9 #include "base/files/file_path.h" |
| 10 #include "base/files/file_util.h" | 10 #include "base/files/file_util.h" |
| (...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 456 std::string message; | 456 std::string message; |
| 457 do { | 457 do { |
| 458 ASSERT_TRUE(message_queue.WaitForMessage(&message)); | 458 ASSERT_TRUE(message_queue.WaitForMessage(&message)); |
| 459 } while (message != "\"GaiaLoaded\""); | 459 } while (message != "\"GaiaLoaded\""); |
| 460 | 460 |
| 461 // Saml flow is gone. | 461 // Saml flow is gone. |
| 462 JsExpect("!$('gaia-signin').classList.contains('saml')"); | 462 JsExpect("!$('gaia-signin').classList.contains('saml')"); |
| 463 } | 463 } |
| 464 | 464 |
| 465 // Tests the sign-in flow when the credentials passing API is used. | 465 // Tests the sign-in flow when the credentials passing API is used. |
| 466 IN_PROC_BROWSER_TEST_F(SamlTest, CredentialPassingAPI) { | 466 // Disabled for flakiness/failing: https://crbug.com/430373 |
| 467 IN_PROC_BROWSER_TEST_F(SamlTest, DISABLED_CredentialPassingAPI) { |
| 467 fake_saml_idp()->SetLoginHTMLTemplate("saml_api_login.html"); | 468 fake_saml_idp()->SetLoginHTMLTemplate("saml_api_login.html"); |
| 468 fake_saml_idp()->SetLoginAuthHTMLTemplate("saml_api_login_auth.html"); | 469 fake_saml_idp()->SetLoginAuthHTMLTemplate("saml_api_login_auth.html"); |
| 469 StartSamlAndWaitForIdpPageLoad(kFirstSAMLUserEmail); | 470 StartSamlAndWaitForIdpPageLoad(kFirstSAMLUserEmail); |
| 470 | 471 |
| 471 // Fill-in the SAML IdP form and submit. | 472 // Fill-in the SAML IdP form and submit. |
| 472 SetSignFormField("Email", "fake_user"); | 473 SetSignFormField("Email", "fake_user"); |
| 473 SetSignFormField("Password", "fake_password"); | 474 SetSignFormField("Password", "fake_password"); |
| 474 ExecuteJsInSigninFrame("document.getElementById('Submit').click();"); | 475 ExecuteJsInSigninFrame("document.getElementById('Submit').click();"); |
| 475 | 476 |
| 476 // Login should finish login and a session should start. | 477 // Login should finish login and a session should start. |
| (...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 953 kTestAuthSIDCookie1, | 954 kTestAuthSIDCookie1, |
| 954 kTestAuthLSIDCookie1); | 955 kTestAuthLSIDCookie1); |
| 955 | 956 |
| 956 GetCookies(); | 957 GetCookies(); |
| 957 EXPECT_EQ(kTestAuthSIDCookie1, GetCookieValue(kGAIASIDCookieName)); | 958 EXPECT_EQ(kTestAuthSIDCookie1, GetCookieValue(kGAIASIDCookieName)); |
| 958 EXPECT_EQ(kTestAuthLSIDCookie1, GetCookieValue(kGAIALSIDCookieName)); | 959 EXPECT_EQ(kTestAuthLSIDCookie1, GetCookieValue(kGAIALSIDCookieName)); |
| 959 EXPECT_EQ(kSAMLIdPCookieValue1, GetCookieValue(kSAMLIdPCookieName)); | 960 EXPECT_EQ(kSAMLIdPCookieValue1, GetCookieValue(kSAMLIdPCookieName)); |
| 960 } | 961 } |
| 961 | 962 |
| 962 } // namespace chromeos | 963 } // namespace chromeos |
| OLD | NEW |