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

Side by Side Diff: remoting/jingle_glue/jingle_channel_unittest.cc

Issue 3181034: Fixed GMock warning about unexpected call in remoting_unittests. (Closed)
Patch Set: Created 10 years, 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "base/ref_counted.h" 5 #include "base/ref_counted.h"
6 #include "media/base/data_buffer.h" 6 #include "media/base/data_buffer.h"
7 #include "remoting/jingle_glue/jingle_channel.h" 7 #include "remoting/jingle_glue/jingle_channel.h"
8 #include "remoting/jingle_glue/jingle_thread.h" 8 #include "remoting/jingle_glue/jingle_thread.h"
9 #include "testing/gmock/include/gmock/gmock.h" 9 #include "testing/gmock/include/gmock/gmock.h"
10 #include "testing/gtest/include/gtest/gtest.h" 10 #include "testing/gtest/include/gtest/gtest.h"
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 MockCallback callback; 131 MockCallback callback;
132 132
133 EXPECT_CALL(*stream, Close()) 133 EXPECT_CALL(*stream, Close())
134 .Times(1); 134 .Times(1);
135 135
136 scoped_refptr<JingleChannel> channel = new JingleChannel(&callback); 136 scoped_refptr<JingleChannel> channel = new JingleChannel(&callback);
137 137
138 channel->thread_ = &thread; 138 channel->thread_ = &thread;
139 channel->stream_.reset(stream); 139 channel->stream_.reset(stream);
140 channel->state_ = JingleChannel::OPEN; 140 channel->state_ = JingleChannel::OPEN;
141
142 EXPECT_CALL(callback, OnStateChange(channel.get(), JingleChannel::CLOSED))
143 .Times(1);
144
141 thread.Start(); 145 thread.Start();
142 channel->Close(); 146 channel->Close();
143 thread.Stop(); 147 thread.Stop();
144 } 148 }
145 149
146 } // namespace remoting 150 } // namespace remoting
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698