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

Side by Side Diff: third_party/WebKit/Source/modules/remoteplayback/RemotePlaybackTest.cpp

Issue 2329463004: ABANDONED CL: Changes needed to make things compile after running rewrite_to_chrome_style tool. (Closed)
Patch Set: More fixes - things build fine at this point. Created 3 years, 8 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 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/remoteplayback/RemotePlayback.h" 5 #include "modules/remoteplayback/RemotePlayback.h"
6 6
7 #include "bindings/core/v8/ExceptionState.h" 7 #include "bindings/core/v8/ExceptionState.h"
8 #include "bindings/core/v8/V8BindingForTesting.h" 8 #include "bindings/core/v8/V8BindingForTesting.h"
9 #include "bindings/modules/v8/RemotePlaybackAvailabilityCallback.h" 9 #include "bindings/modules/v8/RemotePlaybackAvailabilityCallback.h"
10 #include "core/dom/DocumentUserGestureToken.h" 10 #include "core/dom/DocumentUserGestureToken.h"
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
228 V8TestingScope scope; 228 V8TestingScope scope;
229 229
230 auto pageHolder = DummyPageHolder::create(); 230 auto pageHolder = DummyPageHolder::create();
231 231
232 HTMLMediaElement* element = HTMLVideoElement::create(pageHolder->document()); 232 HTMLMediaElement* element = HTMLVideoElement::create(pageHolder->document());
233 RemotePlayback* remotePlayback = 233 RemotePlayback* remotePlayback =
234 HTMLMediaElementRemotePlayback::remote(*element); 234 HTMLMediaElementRemotePlayback::remote(*element);
235 235
236 MockFunction* callbackFunction = MockFunction::create(scope.getScriptState()); 236 MockFunction* callbackFunction = MockFunction::create(scope.getScriptState());
237 RemotePlaybackAvailabilityCallback* availabilityCallback = 237 RemotePlaybackAvailabilityCallback* availabilityCallback =
238 RemotePlaybackAvailabilityCallback::create(scope.getScriptState(), 238 RemotePlaybackAvailabilityCallback::Create(scope.getScriptState(),
239 callbackFunction->bind()); 239 callbackFunction->bind());
240 240
241 // The initial call upon registering will not happen as it's posted on the 241 // The initial call upon registering will not happen as it's posted on the
242 // message loop. 242 // message loop.
243 EXPECT_CALL(*callbackFunction, call(::testing::_)).Times(0); 243 EXPECT_CALL(*callbackFunction, call(::testing::_)).Times(0);
244 244
245 MockFunction* resolve = MockFunction::create(scope.getScriptState()); 245 MockFunction* resolve = MockFunction::create(scope.getScriptState());
246 MockFunction* reject = MockFunction::create(scope.getScriptState()); 246 MockFunction* reject = MockFunction::create(scope.getScriptState());
247 247
248 EXPECT_CALL(*resolve, call(::testing::_)).Times(1); 248 EXPECT_CALL(*resolve, call(::testing::_)).Times(1);
(...skipping 10 matching lines...) Expand all
259 v8::MicrotasksScope::PerformCheckpoint(scope.isolate()); 259 v8::MicrotasksScope::PerformCheckpoint(scope.isolate());
260 260
261 // Verify mock expectations explicitly as the mock objects are garbage 261 // Verify mock expectations explicitly as the mock objects are garbage
262 // collected. 262 // collected.
263 ::testing::Mock::VerifyAndClear(resolve); 263 ::testing::Mock::VerifyAndClear(resolve);
264 ::testing::Mock::VerifyAndClear(reject); 264 ::testing::Mock::VerifyAndClear(reject);
265 ::testing::Mock::VerifyAndClear(callbackFunction); 265 ::testing::Mock::VerifyAndClear(callbackFunction);
266 } 266 }
267 267
268 } // namespace blink 268 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698