Bug 1014708 - Back out testFindInPage changes from bug 958111 and disable testFindInPage. r=gbrown, a=sledru
authorMargaret Leibovic <margaret.leibovic@gmail.com>
Fri, 23 May 2014 18:33:48 -0700
changeset 193412 cca418979066ff20d22a52371018f8f74bfeeee1
parent 193411 d2394f3e3825deb6819d361b8f2c2fc24e23ca17
child 193413 ccf94b264d5d83cbf2fba2ff89b3834b979b66f0
push id474
push userasasaki@mozilla.com
push dateMon, 02 Jun 2014 21:01:02 +0000
treeherdermozilla-release@967f4cf1b31c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgbrown, sledru
bugs1014708, 958111
milestone30.0
Bug 1014708 - Back out testFindInPage changes from bug 958111 and disable testFindInPage. r=gbrown, a=sledru
mobile/android/base/tests/robocop.ini
mobile/android/base/tests/testFindInPage.java
--- a/mobile/android/base/tests/robocop.ini
+++ b/mobile/android/base/tests/robocop.ini
@@ -27,19 +27,17 @@ skip-if = android_version == "10"
 # disabled on 2.3; bug 979603
 skip-if = android_version == "10"
 [testBrowserSearchVisibility]
 [testClearPrivateData]
 # disabled on x86 and 2.3; bug 948591
 skip-if = android_version == "10" || processor == "x86"
 [testDistribution]
 [testDoorHanger]
-[testFindInPage]
-# disabled on Android 2.3; bug 975155
-skip-if = android_version == "10"
+# [testFindInPage] # see bug 975155, bug 1014708
 [testFlingCorrectness]
 # disabled on x86 only; bug 927476
 skip-if = processor == "x86"
 [testFormHistory]
 [testGetUserMedia]
 # disabled on 2.3; bug 979620
 skip-if = android_version == "10"
 # [testHistory] # see bug 915350
--- a/mobile/android/base/tests/testFindInPage.java
+++ b/mobile/android/base/tests/testFindInPage.java
@@ -14,37 +14,34 @@ public class testFindInPage extends Pixe
         return TEST_MOCHITEST;
     }
 
     public void testFindInPage() {
         blockForGeckoReady();
         String url = getAbsoluteUrl("/robocop/robocop_text_page.html");
         loadAndPaint(url);
 
-        // Select the upper left corner of the screen
         height = mDriver.getGeckoHeight()/8;
-        width = mDriver.getGeckoWidth()/8;
+        width = mDriver.getGeckoWidth()/2;
 
-        /* Disabled by bug 958111.
         // Search that does not find the term and therefor should not pan the page
         Actions.RepeatedEventExpecter paintExpecter = mActions.expectPaint();
         findText("Robocoop", 3); // This will be close enough to existing text to test that search finds just what it should
         PaintedSurface painted = waitForPaint(paintExpecter);
         paintExpecter.unregisterListener();
         try {
             mAsserter.ispixel(painted.getPixelAt(width,height), 255, 0, 0, "Pixel at " + String.valueOf(width) + "," + String.valueOf(height));
         } finally {
             painted.close();
         }
-        */
 
         // Search that finds matches and therefor pans the page
-        Actions.RepeatedEventExpecter paintExpecter = mActions.expectPaint();
+        paintExpecter = mActions.expectPaint();
         findText("Robocop", 3);
-        PaintedSurface painted = waitForPaint(paintExpecter);
+        painted = waitForPaint(paintExpecter);
         paintExpecter.unregisterListener();
         try {
             mAsserter.isnotpixel(painted.getPixelAt(width,height), 255, 0, 0, "Pixel at " + String.valueOf(width) + "," + String.valueOf(height));
         } finally {
             painted.close();
         }
     }