1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2025-02-20 20:09:11 +00:00

Merge pull request #270 from jimboatarm/adobereader-s7fix

AdobeReader: Fails on S7 due to search icons being a different class.
This commit is contained in:
setrofim 2016-10-11 16:32:16 +01:00 committed by GitHub
commit fa7d89d734
3 changed files with 6 additions and 5 deletions

0
wlauto/workloads/adobereader/uiauto/build.xml Executable file → Normal file
View File

View File

@ -105,9 +105,11 @@ public class UiAutomation extends UxPerfUiAutomation {
}
// Click the button to search from the present file list view
UiObject searchButton = getUiObjectByResourceId(packageID + "split_pane_search",
"android.widget.TextView",
TimeUnit.SECONDS.toMillis(10));
UiObject searchButton =
new UiObject(new UiSelector().resourceId(packageID + "split_pane_search"));
if (!searchButton.waitForExists(TimeUnit.SECONDS.toMillis(10))) {
throw new UiObjectNotFoundException("Could not find search button");
}
searchButton.click();
// Enter search text into the file searchBox. This will automatically filter the list.
@ -193,8 +195,7 @@ public class UiAutomation extends UxPerfUiAutomation {
// and if not, tap again before continuing
tapDisplayCentre();
UiObject searchIcon =
new UiObject(new UiSelector().resourceId(packageID + "document_view_search_icon")
.className("android.widget.TextView"));
new UiObject(new UiSelector().resourceId(packageID + "document_view_search_icon"));
if (!searchIcon.waitForExists(uiAutoTimeout)) {
tapDisplayCentre();
}