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

Unified Diff: content/public/android/javatests/src/org/chromium/content/browser/DeviceMotionAndOrientationTest.java

Issue 15817019: Additions to the Android java-side Device Motion/Orientation fetching (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixed comments from Marcus Created 7 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/public/android/java/src/org/chromium/content/browser/DeviceMotionAndOrientation.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/android/javatests/src/org/chromium/content/browser/DeviceMotionAndOrientationTest.java
diff --git a/content/public/android/javatests/src/org/chromium/content/browser/DeviceMotionAndOrientationTest.java b/content/public/android/javatests/src/org/chromium/content/browser/DeviceMotionAndOrientationTest.java
index 518b525e6f70841fe84f86b7525d908f62e7ecad..2b51c22abdd9b164acd8586c05b8403389166622 100644
--- a/content/public/android/javatests/src/org/chromium/content/browser/DeviceMotionAndOrientationTest.java
+++ b/content/public/android/javatests/src/org/chromium/content/browser/DeviceMotionAndOrientationTest.java
@@ -58,6 +58,8 @@ public class DeviceMotionAndOrientationTest extends AndroidTestCase {
assertEquals(DeviceMotionAndOrientation.DEVICE_MOTION_SENSORS.size(),
mMockSensorManager.numRegistered);
assertEquals(0, mMockSensorManager.numUnRegistered);
+ assertEquals(DeviceMotionAndOrientation.DEVICE_MOTION_SENSORS.size(),
+ mDeviceMotionAndOrientation.getNumberActiveDeviceMotionSensors());
}
@SmallTest
@@ -101,6 +103,8 @@ public class DeviceMotionAndOrientationTest extends AndroidTestCase {
assertTrue(mDeviceMotionAndOrientation.mDeviceOrientationIsActive);
assertEquals(union.size(), mMockSensorManager.numRegistered);
assertEquals(0, mMockSensorManager.numUnRegistered);
+ assertEquals(DeviceMotionAndOrientation.DEVICE_MOTION_SENSORS.size(),
+ mDeviceMotionAndOrientation.getNumberActiveDeviceMotionSensors());
}
@SmallTest
@@ -114,6 +118,7 @@ public class DeviceMotionAndOrientationTest extends AndroidTestCase {
assertFalse(mDeviceMotionAndOrientation.mDeviceOrientationIsActive);
assertEquals(DeviceMotionAndOrientation.DEVICE_MOTION_SENSORS.size(),
mMockSensorManager.numUnRegistered);
+ assertEquals(0, mDeviceMotionAndOrientation.getNumberActiveDeviceMotionSensors());
}
@SmallTest
@@ -150,6 +155,7 @@ public class DeviceMotionAndOrientationTest extends AndroidTestCase {
mDeviceMotionAndOrientation.mActiveSensors.isEmpty());
assertEquals(diff.size() + DeviceMotionAndOrientation.DEVICE_ORIENTATION_SENSORS.size(),
mMockSensorManager.numUnRegistered);
+ assertEquals(0, mDeviceMotionAndOrientation.getNumberActiveDeviceMotionSensors());
}
@SmallTest
« no previous file with comments | « content/public/android/java/src/org/chromium/content/browser/DeviceMotionAndOrientation.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698