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

Side by Side Diff: content/browser/renderer_host/input/touch_emulator_unittest.cc

Issue 867973002: [DevTools] Ignore TouchEmulator::CancelTouch calls when disabled. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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 | « content/browser/renderer_host/input/touch_emulator.cc ('k') | 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 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 <vector> 5 #include <vector>
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/time/time.h" 10 #include "base/time/time.h"
(...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after
545 545
546 MouseDown(100, 200); 546 MouseDown(100, 200);
547 EXPECT_EQ("TouchStart GestureTapDown", ExpectedEvents()); 547 EXPECT_EQ("TouchStart GestureTapDown", ExpectedEvents());
548 MouseUp(200, 200); 548 MouseUp(200, 200);
549 EXPECT_EQ( 549 EXPECT_EQ(
550 "TouchMove GestureTapCancel GestureScrollBegin GestureScrollUpdate" 550 "TouchMove GestureTapCancel GestureScrollBegin GestureScrollUpdate"
551 " TouchEnd GestureScrollEnd", 551 " TouchEnd GestureScrollEnd",
552 ExpectedEvents()); 552 ExpectedEvents());
553 } 553 }
554 554
555 TEST_F(TouchEmulatorTest, CancelAfterDisableDoesNotCrash) {
556 DisableSynchronousTouchAck();
557 MouseDown(100, 200);
558 emulator()->Disable();
559 EXPECT_EQ("TouchStart TouchCancel", ExpectedEvents());
560 emulator()->CancelTouch();
561 }
562
555 } // namespace content 563 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/input/touch_emulator.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698