Closed Bug 1043720 Opened 10 years ago Closed 8 years ago

Robocop tests fail if screen is dimmed

Categories

(Firefox for Android Graveyard :: Testing, defect)

All
Android
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 1168175

People

(Reporter: bnicholson, Unassigned)

Details

Attachments

(1 file, 1 obsolete file)

I've been frustrated over the past couple of days since Robocop tests would always fail after any period of inactivity on the phone, requiring me to run the tests twice in a row. Turns out that it's due to the screen being dimmed, and the first touch un-dims the screen, but the event doesn't get dispatched.

To prevent this, we should force the screen to stay on during Robocop tests.
Attachment #8462241 - Flags: review?(michael.l.comella)
On all of our production / continuous integration systems, this is done with the WatcherService, http://hg.mozilla.org/mozilla-central/file/613e79262240/build/mobile/sutagent/android/watcher, and applies to all of our tests (mochitests, reftests, etc).
(In reply to Geoff Brown [:gbrown] from comment #2)
> On all of our production / continuous integration systems, this is done with
> the WatcherService,
> http://hg.mozilla.org/mozilla-central/file/613e79262240/build/mobile/
> sutagent/android/watcher, and applies to all of our tests (mochitests,
> reftests, etc).

Interesting -- so what does that mean for this bug? Should we figure out a way to merge the two approaches somehow? Or should we keep this patch, which will effectively be a no-op on those systems?
Just remembered that we have a runOnUiThreadSync() helper in RobocopUtils, so that makes things simpler.
Attachment #8462241 - Attachment is obsolete: true
Attachment #8462241 - Flags: review?(michael.l.comella)
Attachment #8462263 - Flags: review?(gbrown)
Comment on attachment 8462263 [details] [diff] [review]
Keep screen on during Robocop tests, v2

Review of attachment 8462263 [details] [diff] [review]:
-----------------------------------------------------------------

Installing the WatcherService on local devices is an alternative, but this is more convenient.
Attachment #8462263 - Flags: review?(gbrown) → review+
Not sure what's going on here, but this isn't really a high priority. Putting this one in my backlog.
Flags: needinfo?(bnicholson)
Assignee: bnicholson → nobody
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → DUPLICATE
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: