Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(567)

Side by Side Diff: components/password_manager/content/browser/content_password_manager_driver_unittest.cc

Issue 2420253002: Rename shell namespace to service_manager (Closed)
Patch Set: . Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "components/password_manager/content/browser/content_password_manager_d river.h" 5 #include "components/password_manager/content/browser/content_password_manager_d river.h"
6 6
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "base/run_loop.h" 8 #include "base/run_loop.h"
9 #include "components/autofill/content/public/interfaces/autofill_agent.mojom.h" 9 #include "components/autofill/content/public/interfaces/autofill_agent.mojom.h"
10 #include "components/autofill/core/browser/test_autofill_client.h" 10 #include "components/autofill/core/browser/test_autofill_client.h"
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 94
95 class ContentPasswordManagerDriverTest 95 class ContentPasswordManagerDriverTest
96 : public content::RenderViewHostTestHarness, 96 : public content::RenderViewHostTestHarness,
97 public testing::WithParamInterface<bool> { 97 public testing::WithParamInterface<bool> {
98 public: 98 public:
99 void SetUp() override { 99 void SetUp() override {
100 content::RenderViewHostTestHarness::SetUp(); 100 content::RenderViewHostTestHarness::SetUp();
101 ON_CALL(password_manager_client_, GetLogManager()) 101 ON_CALL(password_manager_client_, GetLogManager())
102 .WillByDefault(Return(&log_manager_)); 102 .WillByDefault(Return(&log_manager_));
103 103
104 shell::InterfaceProvider* remote_interfaces = 104 service_manager::InterfaceProvider* remote_interfaces =
105 web_contents()->GetMainFrame()->GetRemoteInterfaces(); 105 web_contents()->GetMainFrame()->GetRemoteInterfaces();
106 shell::InterfaceProvider::TestApi test_api(remote_interfaces); 106 service_manager::InterfaceProvider::TestApi test_api(remote_interfaces);
107 test_api.SetBinderForName( 107 test_api.SetBinderForName(
108 autofill::mojom::PasswordAutofillAgent::Name_, 108 autofill::mojom::PasswordAutofillAgent::Name_,
109 base::Bind(&FakePasswordAutofillAgent::BindRequest, 109 base::Bind(&FakePasswordAutofillAgent::BindRequest,
110 base::Unretained(&fake_agent_))); 110 base::Unretained(&fake_agent_)));
111 } 111 }
112 112
113 bool WasLoggingActivationMessageSent(bool* activation_flag) { 113 bool WasLoggingActivationMessageSent(bool* activation_flag) {
114 base::RunLoop().RunUntilIdle(); 114 base::RunLoop().RunUntilIdle();
115 if (!fake_agent_.called_set_logging_state()) 115 if (!fake_agent_.called_set_logging_state())
116 return false; 116 return false;
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 EXPECT_EQ(url, entry->GetURL()); 196 EXPECT_EQ(url, entry->GetURL());
197 EXPECT_TRUE(!!(entry->GetSSL().content_status & 197 EXPECT_TRUE(!!(entry->GetSSL().content_status &
198 content::SSLStatus::DISPLAYED_PASSWORD_FIELD_ON_HTTP)); 198 content::SSLStatus::DISPLAYED_PASSWORD_FIELD_ON_HTTP));
199 } 199 }
200 200
201 INSTANTIATE_TEST_CASE_P(, 201 INSTANTIATE_TEST_CASE_P(,
202 ContentPasswordManagerDriverTest, 202 ContentPasswordManagerDriverTest,
203 testing::Values(true, false)); 203 testing::Values(true, false));
204 204
205 } // namespace password_manager 205 } // namespace password_manager
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698