| OLD | NEW |
| 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 package org.chromium.chromoting; | 5 package org.chromium.chromoting; |
| 6 | 6 |
| 7 import android.support.test.filters.SmallTest; |
| 7 import android.test.InstrumentationTestCase; | 8 import android.test.InstrumentationTestCase; |
| 8 import android.test.suitebuilder.annotation.SmallTest; | |
| 9 import android.view.MotionEvent; | 9 import android.view.MotionEvent; |
| 10 import android.view.ViewConfiguration; | 10 import android.view.ViewConfiguration; |
| 11 | 11 |
| 12 import org.chromium.base.ThreadUtils; | 12 import org.chromium.base.ThreadUtils; |
| 13 import org.chromium.base.test.util.Feature; | 13 import org.chromium.base.test.util.Feature; |
| 14 | 14 |
| 15 /** Tests for {@link TapGestureDetector}. */ | 15 /** Tests for {@link TapGestureDetector}. */ |
| 16 public class TapGestureDetectorTest extends InstrumentationTestCase { | 16 public class TapGestureDetectorTest extends InstrumentationTestCase { |
| 17 private static class MockListener implements TapGestureDetector.OnTapListene
r { | 17 private static class MockListener implements TapGestureDetector.OnTapListene
r { |
| 18 private static final float COMPARISON_DELTA = 0.01f; | 18 private static final float COMPARISON_DELTA = 0.01f; |
| (...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 ThreadUtils.runOnUiThreadBlocking(new Runnable() { | 182 ThreadUtils.runOnUiThreadBlocking(new Runnable() { |
| 183 @Override | 183 @Override |
| 184 public void run() { | 184 public void run() { |
| 185 injectUpEvent(0); | 185 injectUpEvent(0); |
| 186 } | 186 } |
| 187 }); | 187 }); |
| 188 | 188 |
| 189 mListener.assertLongPressDetected(1, 0, 0); | 189 mListener.assertLongPressDetected(1, 0, 0); |
| 190 } | 190 } |
| 191 } | 191 } |
| OLD | NEW |