Bug 717349 - Add a checkerboarding test to Robotium. r=jmaher a=akeybl
☠☠ backed out by 65c1ea711b91 ☠ ☠
authorChris Lord <chrislord.net@gmail.com>
Thu, 02 Feb 2012 09:03:37 +0000
changeset 88348 0eac67dba10fdf213b0980adb2a62a602575e9bb
parent 88347 aeb3e5db799e88c7a800839accf3e7d34a80df3c
child 88349 fefd5adb4134563c72f94c891f557c2989fe7b65
push idunknown
push userunknown
push dateunknown
reviewersjmaher, akeybl
bugs717349
milestone12.0a2
Bug 717349 - Add a checkerboarding test to Robotium. r=jmaher a=akeybl Copy testPan, but make it record checkerboarded frames instead of dropped frames.
mobile/android/base/tests/robocop.ini
mobile/android/base/tests/testCheck.java.in
--- a/mobile/android/base/tests/robocop.ini
+++ b/mobile/android/base/tests/robocop.ini
@@ -1,7 +1,8 @@
 [testAwesomebar]
 [testBookmark]
 [testLoad]
 [testNewTab]
 
 # Used for Talos, please don't use in mochitest
 #[testPan]
+#[testCheck]
copy from mobile/android/base/tests/testPan.java.in
copy to mobile/android/base/tests/testCheck.java.in
--- a/mobile/android/base/tests/testPan.java.in
+++ b/mobile/android/base/tests/testCheck.java.in
@@ -1,39 +1,39 @@
 #filter substitution
 package @ANDROID_PACKAGE_NAME@.tests;
 
 import @ANDROID_PACKAGE_NAME@.*;
 
-public class testPan extends BaseTest {
+public class testCheck extends BaseTest {
     private static final String URL = "http://mochi.test:8888/startup_test/fenncmark/wikipedia.html";
 
-    public void testPan() {
+    public void testCheck() {
         loadUrl(URL);
 
         mDriver.setupScrollHandling();
 
         // Setup scrolling coordinates.
         int midX = mDriver.getGeckoLeft() + mDriver.getGeckoWidth()/2;
         int midY = mDriver.getGeckoTop() + mDriver.getGeckoHeight()/2;
         int endY = mDriver.getGeckoTop() + mDriver.getGeckoHeight()/10;
 
-        mDriver.startFrameRecording();
+        mDriver.startCheckerboardRecording();
 
         int i = 0;
         // Scroll a thousand times or until the end of the page.
         do {
             mActions.drag(midX, midX, midY, endY);
             try {
                 Thread.sleep(200);
             } catch (InterruptedException e) {
                 e.printStackTrace();
             }
             i++;
         } while (i < 1000 && mDriver.getScrollHeight() + 2 * mDriver.getHeight() < mDriver.getPageHeight());
         // asserter.ok(i < 1000, "Less than 1000", "Should take less than 1000 drags to get to bottom of the page.");
 
-        int frames = mDriver.stopFrameRecording();
-        mAsserter.dumpLog("__start_report" + Integer.toString(frames) + "__end_report");
+        int incompleteFrames = mDriver.stopCheckerboardRecording();
+        mAsserter.dumpLog("__start_report" + Integer.toString(incompleteFrames) + "__end_report");
         long msecs = System.currentTimeMillis();
         mAsserter.dumpLog("__startTimestamp" + msecs + "__endTimestamp");
     }	
 }