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

Unified Diff: chrome/renderer/autofill/password_generation_agent_browsertest.cc

Issue 563313004: [Password Manager] Unfriend PasswordAutofillAgentTest from PasswordAutofillAgent (clean-up). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Unfriend PasswordAutofillAgentTest and RequestAutocompleteRendererTest from AutofillAgent. Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: chrome/renderer/autofill/password_generation_agent_browsertest.cc
diff --git a/chrome/renderer/autofill/password_generation_agent_browsertest.cc b/chrome/renderer/autofill/password_generation_agent_browsertest.cc
index 60bdaa3efa8a9c77e86dc2d7997968038f342b55..01d45ac2cb20ac66b406e8a2a6e7de3609d1afd6 100644
--- a/chrome/renderer/autofill/password_generation_agent_browsertest.cc
+++ b/chrome/renderer/autofill/password_generation_agent_browsertest.cc
@@ -200,8 +200,9 @@ TEST_F(PasswordGenerationAgentTest, EditingTest) {
base::string16 edited_password = base::ASCIIToUTF16("edited_password");
first_password_element.setValue(edited_password);
// Cast to WebAutofillClient where textFieldDidChange() is public.
- static_cast<blink::WebAutofillClient*>(autofill_agent_)->textFieldDidChange(
- first_password_element);
+ AutofillAgent* autofill_agent = (AutofillAgent*)autofill_agent_;
vabr (Chromium) 2014/09/15 14:26:59 Don't use C-style cast, use one of C++ casts. (htt
Pritam Nikam 2014/09/16 07:54:19 Done. I've missed including header earlier.
+ static_cast<blink::WebAutofillClient*>(autofill_agent)
+ ->textFieldDidChange(first_password_element);
// textFieldDidChange posts a task, so we need to wait until it's been
// processed.
base::MessageLoop::current()->RunUntilIdle();
@@ -272,8 +273,9 @@ TEST_F(PasswordGenerationAgentTest, MaximumOfferSize) {
base::ASCIIToUTF16(
std::string(password_generation_->kMaximumOfferSize - 1, 'a')));
// Cast to WebAutofillClient where textFieldDidChange() is public.
- static_cast<blink::WebAutofillClient*>(autofill_agent_)->textFieldDidChange(
- first_password_element);
+ AutofillAgent* autofill_agent = (AutofillAgent*)autofill_agent_;
+ static_cast<blink::WebAutofillClient*>(autofill_agent)
+ ->textFieldDidChange(first_password_element);
// textFieldDidChange posts a task, so we need to wait until it's been
// processed.
base::MessageLoop::current()->RunUntilIdle();
@@ -288,8 +290,8 @@ TEST_F(PasswordGenerationAgentTest, MaximumOfferSize) {
base::ASCIIToUTF16(
std::string(password_generation_->kMaximumOfferSize + 1, 'a')));
// Cast to WebAutofillClient where textFieldDidChange() is public.
- static_cast<blink::WebAutofillClient*>(autofill_agent_)->textFieldDidChange(
- first_password_element);
+ static_cast<blink::WebAutofillClient*>(autofill_agent)
+ ->textFieldDidChange(first_password_element);
// textFieldDidChange posts a task, so we need to wait until it's been
// processed.
base::MessageLoop::current()->RunUntilIdle();
@@ -305,8 +307,8 @@ TEST_F(PasswordGenerationAgentTest, MaximumOfferSize) {
base::ASCIIToUTF16(
std::string(password_generation_->kMaximumOfferSize, 'a')));
// Cast to WebAutofillClient where textFieldDidChange() is public.
- static_cast<blink::WebAutofillClient*>(autofill_agent_)->textFieldDidChange(
- first_password_element);
+ static_cast<blink::WebAutofillClient*>(autofill_agent)
+ ->textFieldDidChange(first_password_element);
// textFieldDidChange posts a task, so we need to wait until it's been
// processed.
base::MessageLoop::current()->RunUntilIdle();

Powered by Google App Engine
This is Rietveld 408576698