| Index: chrome/browser/ui/passwords/test_manage_passwords_bubble_ui_controller.h
|
| diff --git a/chrome/browser/ui/passwords/test_manage_passwords_bubble_ui_controller.h b/chrome/browser/ui/passwords/test_manage_passwords_bubble_ui_controller.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..6952ef1ad36a4d79f7b80c6f85beeb98374b50ba
|
| --- /dev/null
|
| +++ b/chrome/browser/ui/passwords/test_manage_passwords_bubble_ui_controller.h
|
| @@ -0,0 +1,46 @@
|
| +// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef CHROME_BROWSER_UI_PASSWORDS_TEST_MANAGE_PASSWORDS_BUBBLE_UI_CONTROLLER_H_
|
| +#define CHROME_BROWSER_UI_PASSWORDS_TEST_MANAGE_PASSWORDS_BUBBLE_UI_CONTROLLER_H_
|
| +
|
| +#include "base/basictypes.h"
|
| +#include "chrome/browser/ui/passwords/manage_passwords_bubble_ui_controller.h"
|
| +
|
| +namespace content {
|
| +class WebContents;
|
| +} // namespace content
|
| +
|
| +class TestManagePasswordsBubbleUIController
|
| + : public ManagePasswordsBubbleUIController {
|
| + public:
|
| + explicit TestManagePasswordsBubbleUIController(
|
| + content::WebContents* contents);
|
| + virtual ~TestManagePasswordsBubbleUIController();
|
| +
|
| + // Don't _actually_ navigate in a test. That would be silly.
|
| + virtual void NavigateToPasswordManagerSettingsPage() OVERRIDE;
|
| + bool navigated_to_settings_page() const {
|
| + return navigated_to_settings_page_;
|
| + }
|
| +
|
| + // We don't have a FormManager in tests, so stub these out.
|
| + virtual void SavePassword() OVERRIDE;
|
| + bool saved_password() const { return saved_password_; }
|
| +
|
| + virtual void NeverSavePassword() OVERRIDE;
|
| + bool never_saved_password() const { return never_saved_password_; }
|
| +
|
| + // True if this controller is installed on |web_contents()|.
|
| + bool IsInstalled() const;
|
| +
|
| + private:
|
| + bool navigated_to_settings_page_;
|
| + bool saved_password_;
|
| + bool never_saved_password_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(TestManagePasswordsBubbleUIController);
|
| +};
|
| +
|
| +#endif // CHROME_BROWSER_UI_PASSWORDS_TEST_MANAGE_PASSWORDS_BUBBLE_UI_CONTROLLER_H_
|
|
|