Skip to content

Commit

Permalink
HPCC-31857 - Change the way of accessing web element
Browse files Browse the repository at this point in the history
  • Loading branch information
Nisha-Bagdwal committed Jul 18, 2024
1 parent 8f7d39e commit c2f02e4
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion esp/src/test-ui/tests/framework/pages/BaseTableTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,12 @@ private String getCurrentSortingOrder(String columnKey) {

try {

WebElement columnHeader = Common.driver.findElement(By.xpath("//*[@*[.='" + columnKey + "']]"));
//WebElement columnHeader = Common.driver.findElement(By.xpath("//*[@*[.='" + columnKey + "']]"));

WebElement columnHeader = Common.driver.findElement(By.xpath("//*[@role='columnheader' and @*[.='" + columnKey + "']]"));

// Scroll into view
//((JavascriptExecutor) Common.driver).executeScript("arguments[0].scrollIntoView(true);", columnHeader);

String oldSortOrder = columnHeader.getAttribute("aria-sort");

Expand Down

0 comments on commit c2f02e4

Please sign in to comment.