1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2024-10-06 10:51:13 +01:00

vellamo: fixing capitalization in automation

Capitalization for the "LET'S ROLL" button text was incorrect in the
automation code. This has not caused issues up to this point, but it
seems the button is no longer being found in the latest AOSP. This
commit corrects the capitalization.
This commit is contained in:
Sergei Trofimov 2016-10-07 17:21:56 +01:00
parent 6aecf1b35e
commit edc26fe75c
2 changed files with 7 additions and 2 deletions

View File

@ -241,10 +241,15 @@ public class UiAutomation extends BaseUiAutomation {
public void dismissLetsRoll() throws Exception {
UiSelector selector = new UiSelector();
UiObject letsRollButton = new UiObject(selector.className("android.widget.Button")
.textContains("Let's Roll"));
.textContains("LET'S ROLL"));
if (!letsRollButton.waitForExists(TimeUnit.SECONDS.toMillis(5))) {
if (!letsRollButton.exists()) {
throw new UiObjectNotFoundException("Could not find \"Let's Roll\" button.");
// As a fall-back look for the old capitalization
letsRollButton = new UiObject(selector.className("android.widget.Button")
.textContains("Let's Roll"));
if (!letsRollButton.exists()) {
throw new UiObjectNotFoundException("Could not find \"Let's Roll\" button.");
}
}
}
letsRollButton.click();