Access components inside a PolymerTemplate with vaadin-testbench

in our project we are using the vaadin designer. The designer creates all components in a PolymerTemplate.
Now we want to start with testing by using vaadin testbench.
The problem is, that the components in the PolymerTemplate are hidden in a shadow-dom, vaadin techbench can’t access them.
I tried for example $(LabelElement.class).waitForFirst() the get an label from inside the PolymerTemplate, but vaadin techbench can’t find it.
When I don’t use the PolymerTemplate, then vaadin techbench finds the label.

So my question is, is there a way to access the components inside the PolymerTemplate with vaadin techbench?


Hi, after a day searching and testing, I find a solution.
First you have to search the PolymerTemplate with testbench and the you can search for inner elements.

TestBenchElement viewShadow = $(TestBenchElement.class).id("ID from PolymerTemplate");