Skip to content

Commit

Permalink
test: wait for element before getting text (#129)
Browse files Browse the repository at this point in the history
  • Loading branch information
mcollovati authored Nov 10, 2024
1 parent 1482889 commit ba83677
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ protected void follow(String linkText) {
}

protected String getText(String id) {
return findElement(By.id(id)).getText();
return waitUntil(d -> findElement(By.id(id))).getText();
}

protected void assertCountEquals(int expectedCount, String counter) throws IOException {
Expand Down

0 comments on commit ba83677

Please sign in to comment.