Skip to content

Commit

Permalink
Page steps optimize (#16)
Browse files Browse the repository at this point in the history
* optimize checkText method for iOS

* del qualifier

* fix iOSNSPredicate in checkText (remove content-desc)
  • Loading branch information
JasperJhons authored and Yaromudr committed Aug 31, 2017
1 parent 5adb24d commit e351666
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/ru/colibri/ui/steps/ios/IOSPageSteps.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,6 @@ public void checkNoElement(@Named("$elementName") String elementName) {
@Then("на экране есть надпись \"$textOrKeyword\"")
public void checkText(@Named("$textOrKeyword") String textOrKeyword) {
String text = propertyUtils.injectProperties(textOrKeyword);
driver.findElement(MobileBy.iOSNsPredicateString(format("name contains '%1$s' or text contains '%1$s' or value contains '%1$s' or content-desc contains '%1$s'", text)));
driver.findElement(MobileBy.iOSNsPredicateString(format("name contains '%1$s' or value contains '%1$s' or label contains '%1$s'", text)));
}
}

0 comments on commit e351666

Please sign in to comment.