Skip to content

Commit

Permalink
revert
Browse files Browse the repository at this point in the history
  • Loading branch information
vculea committed Aug 27, 2024
1 parent 63ec718 commit e23b932
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/main/java/com/sdl/selenium/web/XPathBuilder.java
Original file line number Diff line number Diff line change
Expand Up @@ -1067,11 +1067,7 @@ public void addTextInPath(List<String> selectors, String text, String pattern, L
String escapeQuotesText = Utils.getEscapeQuotesText(strings[i]);
if (searchTextType.contains(SearchType.CONTAINS_ALL_CHILD_NODES)) {
if (searchTextType.contains(SearchType.CASE_INSENSITIVE)) {
if (strings[i].equals("'")) {
strings[i] = "count(*//text()[contains(translate(.,\\\"" + strings[i].replaceAll("CONCAT\\(", "concat(") + "\\\",\\\"" + strings[i] + "\\\"),\\\"" + strings[i] + "\\\")]) > 0";
} else {
strings[i] = "count(*//text()[contains(translate(.," + escapeQuotesText.toUpperCase().replaceAll("CONCAT\\(", "concat(") + "," + escapeQuotesText.toLowerCase() + ")," + escapeQuotesText.toLowerCase() + ")]) > 0";
}
strings[i] = "count(*//text()[contains(translate(.," + escapeQuotesText.toUpperCase().replaceAll("CONCAT\\(", "concat(") + "," + escapeQuotesText.toLowerCase() + ")," + escapeQuotesText.toLowerCase() + ")]) > 0";
} else {
strings[i] = "count(*//text()[contains(.," + escapeQuotesText + ")]) > 0";
}
Expand Down

0 comments on commit e23b932

Please sign in to comment.