Skip to content

Commit

Permalink
Wait for shadow-root child in ChildOrderIT
Browse files Browse the repository at this point in the history
  • Loading branch information
pekam committed Jun 18, 2018
1 parent 222eff2 commit 1d40a78
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import org.junit.Before;
import org.junit.Test;
import org.openqa.selenium.By;
import org.openqa.selenium.NoSuchElementException;
import org.openqa.selenium.WebElement;

import com.vaadin.flow.component.html.testbench.DivElement;
Expand All @@ -44,6 +45,14 @@ public void init() {
open();
waitForElementPresent(By.tagName("child-order-template"));
root = $("child-order-template").first();
waitUntil(driver -> {
try {
root.$(DivElement.class).id("containerWithElement");
} catch (NoSuchElementException e) {
return false;
}
return true;
});
}

@Test
Expand Down

0 comments on commit 1d40a78

Please sign in to comment.