Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/org/labkey/test/components/ui/grids/QueryGrid.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
import org.labkey.test.util.selenium.WebElementUtils;
import org.openqa.selenium.Keys;
import org.openqa.selenium.NoSuchElementException;
import org.openqa.selenium.StaleElementReferenceException;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.interactions.Actions;
Expand Down Expand Up @@ -642,6 +643,12 @@ public String getEditAlertText()
* @return The name of the grid view from the header. Empty string if no header (default view).
*/
public String getViewName()
{
// The header re-renders while the grid reloads, so find it again if it goes stale
return getWrapper().shortWait().ignoring(StaleElementReferenceException.class).until(_ -> readViewName());
}

private String readViewName()
{
String viewName;

Expand Down