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

Side by Side Diff: third_party/WebKit/Source/modules/payments/PaymentTestHelper.cpp

Issue 2175613003: Fix GMOCK WARNING: Uninteresting mock function call - taking default action. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "modules/payments/PaymentTestHelper.h" 5 #include "modules/payments/PaymentTestHelper.h"
6 6
7 #include "bindings/core/v8/ScriptState.h" 7 #include "bindings/core/v8/ScriptState.h"
8 #include "core/dom/Document.h" 8 #include "core/dom/Document.h"
9 #include "modules/payments/PaymentCurrencyAmount.h" 9 #include "modules/payments/PaymentCurrencyAmount.h"
10 #include "modules/payments/PaymentMethodData.h" 10 #include "modules/payments/PaymentMethodData.h"
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 { 150 {
151 v8::MicrotasksScope::PerformCheckpoint(m_scriptState->isolate()); 151 v8::MicrotasksScope::PerformCheckpoint(m_scriptState->isolate());
152 for (MockFunction* mockFunction : m_mockFunctions) { 152 for (MockFunction* mockFunction : m_mockFunctions) {
153 testing::Mock::VerifyAndClearExpectations(mockFunction); 153 testing::Mock::VerifyAndClearExpectations(mockFunction);
154 } 154 }
155 } 155 }
156 156
157 v8::Local<v8::Function> PaymentRequestMockFunctionScope::expectCall(String* capt or) 157 v8::Local<v8::Function> PaymentRequestMockFunctionScope::expectCall(String* capt or)
158 { 158 {
159 m_mockFunctions.append(new MockFunction(m_scriptState, captor)); 159 m_mockFunctions.append(new MockFunction(m_scriptState, captor));
160 EXPECT_CALL(*m_mockFunctions.last(), call(testing::_));
160 return m_mockFunctions.last()->bind(); 161 return m_mockFunctions.last()->bind();
161 } 162 }
162 163
163 v8::Local<v8::Function> PaymentRequestMockFunctionScope::expectCall() 164 v8::Local<v8::Function> PaymentRequestMockFunctionScope::expectCall()
164 { 165 {
165 m_mockFunctions.append(new MockFunction(m_scriptState)); 166 m_mockFunctions.append(new MockFunction(m_scriptState));
166 EXPECT_CALL(*m_mockFunctions.last(), call(testing::_)); 167 EXPECT_CALL(*m_mockFunctions.last(), call(testing::_));
167 return m_mockFunctions.last()->bind(); 168 return m_mockFunctions.last()->bind();
168 } 169 }
169 170
(...skipping 22 matching lines...) Expand all
192 ON_CALL(*this, call(testing::_)).WillByDefault( 193 ON_CALL(*this, call(testing::_)).WillByDefault(
193 testing::DoAll(SaveValueIn(m_value), testing::ReturnArg<0>())); 194 testing::DoAll(SaveValueIn(m_value), testing::ReturnArg<0>()));
194 } 195 }
195 196
196 v8::Local<v8::Function> PaymentRequestMockFunctionScope::MockFunction::bind() 197 v8::Local<v8::Function> PaymentRequestMockFunctionScope::MockFunction::bind()
197 { 198 {
198 return bindToV8Function(); 199 return bindToV8Function();
199 } 200 }
200 201
201 } // namespace blink 202 } // namespace blink
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