How to test Polymer 2 components with Protractor when /deep/ will be deprecated?

179 views
Skip to first unread message

peter...@gmail.com

unread,
Sep 28, 2017, 11:18:01 AM9/28/17
to Polymer
My organization is going to be moving to Polymer 2 and with that they will have to move away from the shady dom to the shadow dom. I do know that /deep/ is being deprecated? Is there going to be something that will substitute for /deep/ that we can use in place when using Selenium and Protractor and Mocha?

peter...@gmail.com

unread,
Sep 29, 2017, 1:58:48 PM9/29/17
to Polymer
I will reply with something i found on slack overflow

"The piercing selector is being dropped (/deep/ and >>>). There's currently no other alternative to search through the whole DOM with a single query. The current solution is to implement a custom selector taking multiple CSS segments to search each context"

Karl Tiedt

unread,
Sep 29, 2017, 2:09:09 PM9/29/17
to peter...@gmail.com, Polymer
The more important question... why do you feel you need /deep/ to test components?

-Karl Tiedt

Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/52149efb-bb20-46ce-aa38-dafe9c708adc%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

peter...@gmail.com

unread,
Oct 2, 2017, 2:20:54 PM10/2/17
to Polymer
We have a website that in each page there are multiple components, so we need to run acceptance tests to pierce each component and test them


On Friday, September 29, 2017 at 12:09:09 PM UTC-6, Karl Tiedt wrote:
The more important question... why do you feel you need /deep/ to test components?

-Karl Tiedt

On Fri, Sep 29, 2017 at 12:58 PM, <peter...@gmail.com> wrote:
I will reply with something i found on slack overflow

"The piercing selector is being dropped (/deep/ and >>>). There's currently no other alternative to search through the whole DOM with a single query. The current solution is to implement a custom selector taking multiple CSS segments to search each context"

On Thursday, September 28, 2017 at 9:18:01 AM UTC-6, peter...@gmail.com wrote:
My organization is going to be moving to Polymer 2 and with that they will have to move away from the shady dom to the shadow dom. I do know that /deep/ is being deprecated? Is there going to be something that will substitute for /deep/ that we can use in place when using Selenium and Protractor and Mocha?

Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.

Karl Tiedt

unread,
Oct 2, 2017, 2:25:30 PM10/2/17
to Ryan Petersen, Polymer
Sounds like you are over complicating things... The component tests should cover components styling and CSS (including CSS variables that can be affected externally)... Integration tests (and beyond) shouldn't care about that... End To End or Integration tests should just be confirming proper input nets proper output (or page/view changes etc).


-Karl Tiedt

To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/0f92cce9-a733-4391-8b7d-dacc1f70620f%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages