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

Side by Side Diff: remoting/host/it2me/it2me_confirmation_dialog_proxy_unittest.cc

Issue 1680643002: Refactor gmock_mutant.h (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 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 "remoting/host/it2me/it2me_confirmation_dialog_proxy.h" 5 #include "remoting/host/it2me/it2me_confirmation_dialog_proxy.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/run_loop.h" 10 #include "base/run_loop.h"
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 125
126 It2MeConfirmationDialogProxyTest::~It2MeConfirmationDialogProxyTest() {} 126 It2MeConfirmationDialogProxyTest::~It2MeConfirmationDialogProxyTest() {}
127 127
128 TEST_F(It2MeConfirmationDialogProxyTest, Show) { 128 TEST_F(It2MeConfirmationDialogProxyTest, Show) {
129 ResultCallbackTarget callback_target(main_task_runner()); 129 ResultCallbackTarget callback_target(main_task_runner());
130 130
131 EXPECT_CALL(*dialog(), OnShow()) 131 EXPECT_CALL(*dialog(), OnShow())
132 .WillOnce( 132 .WillOnce(
133 InvokeWithoutArgs( 133 InvokeWithoutArgs(
134 CreateFunctor( 134 CreateFunctor(
135 dialog(), &StubIt2MeConfirmationDialog::ReportResult, 135 &StubIt2MeConfirmationDialog::ReportResult,
136 base::Unretained(dialog()),
136 It2MeConfirmationDialog::Result::CANCEL))); 137 It2MeConfirmationDialog::Result::CANCEL)));
137 138
138 EXPECT_CALL(callback_target, 139 EXPECT_CALL(callback_target,
139 OnDialogResult(It2MeConfirmationDialog::Result::CANCEL)) 140 OnDialogResult(It2MeConfirmationDialog::Result::CANCEL))
140 .WillOnce( 141 .WillOnce(
141 InvokeWithoutArgs(this, &It2MeConfirmationDialogProxyTest::Quit)); 142 InvokeWithoutArgs(this, &It2MeConfirmationDialogProxyTest::Quit));
142 143
143 dialog_proxy()->Show(callback_target.MakeCallback()); 144 dialog_proxy()->Show(callback_target.MakeCallback());
144 145
145 Run(); 146 Run();
146 } 147 }
147 148
148 } // namespace remoting 149 } // namespace remoting
OLDNEW
« no previous file with comments | « net/quic/quic_stream_sequencer_test.cc ('k') | remoting/host/win/worker_process_launcher_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698