| Index: chrome/browser/ui/cocoa/passwords/confirmation_password_saved_view_controller_unittest.mm
|
| diff --git a/chrome/browser/ui/cocoa/passwords/confirmation_password_saved_view_controller_unittest.mm b/chrome/browser/ui/cocoa/passwords/confirmation_password_saved_view_controller_unittest.mm
|
| index e8c903a84bc9d9daf94e26d0d4e050883dfb221f..26fea09dd8a711a5a99ef1ba05482e6ac0207ce7 100644
|
| --- a/chrome/browser/ui/cocoa/passwords/confirmation_password_saved_view_controller_unittest.mm
|
| +++ b/chrome/browser/ui/cocoa/passwords/confirmation_password_saved_view_controller_unittest.mm
|
| @@ -20,29 +20,20 @@ namespace {
|
| class ConfirmationPasswordSavedViewControllerTest
|
| : public ManagePasswordsControllerTest {
|
| public:
|
| - ConfirmationPasswordSavedViewControllerTest() : controller_(nil) {}
|
| -
|
| void SetUp() override {
|
| ManagePasswordsControllerTest::SetUp();
|
| - delegate_.reset([[ContentViewDelegateMock alloc] init]);
|
| SetUpConfirmationState();
|
| + controller_.reset([[ConfirmationPasswordSavedViewController alloc]
|
| + initWithDelegate:delegate()]);
|
| + [controller_ view];
|
| }
|
|
|
| - ContentViewDelegateMock* delegate() { return delegate_.get(); }
|
| -
|
| ConfirmationPasswordSavedViewController* controller() {
|
| - if (!controller_) {
|
| - [delegate() setModel:GetModelAndCreateIfNull()];
|
| - controller_.reset([[ConfirmationPasswordSavedViewController alloc]
|
| - initWithDelegate:delegate()]);
|
| - [controller_ view];
|
| - }
|
| return controller_.get();
|
| }
|
|
|
| private:
|
| base::scoped_nsobject<ConfirmationPasswordSavedViewController> controller_;
|
| - base::scoped_nsobject<ContentViewDelegateMock> delegate_;
|
| };
|
|
|
| TEST_F(ConfirmationPasswordSavedViewControllerTest,
|
| @@ -63,7 +54,6 @@ TEST_F(ConfirmationPasswordSavedViewControllerTest, CloseBubbleAndHandleClick) {
|
| // still sends the action.
|
| EXPECT_CALL(*ui_controller(), NavigateToPasswordManagerSettingsPage())
|
| .Times(0);
|
| - [controller() bubbleWillDisappear];
|
| [delegate() setModel:nil];
|
| [controller().confirmationText clickedOnLink:@"about:blank" atIndex:0];
|
| [controller().okButton performClick:nil];
|
|
|