Closed branislav-remen closed 1 year ago
@branislav-remen can you share a reproducible html page with shadow dom?
@branislav-remen can you share a reproducible html page with shadow dom?
for example: https://www.axa.ch/en/myaxa/company-registration.html#/
Heading (on top of the page) and Button (on bottom) use shadow dom. Details about components used on this page can be found here: https://github.com/axa-ch-webhub-cloud/pattern-library
@branislav-remen can you give v1.19.1-alpha.0 a try?
@itsjwala it works with v1.19.1-alpha.0 👍 Thank you. 👏
But I see some warnings not related to the topic of this issue:
[percy] Heads up! The current version of @percy/cli is more than 10 releases behind! 1.19.1-alpha.0 -> 1.19.0-alpha.0
- This message is confusing 😄 Stylesheet related warnings, but screenshots in Percy looks correctly (1:1 with real website).
Running 24 tests using 1 worker
1 [chromium] › src/tests/visualRegression.spec.ts:28:1 › Registrations page
[percy] Snapshot taken: Registrations page-card
[percy] Encountered snapshot serialization warnings:
[percy] - stylesheet with attributes - [ data-name: axa-table-myaxa ] - was not serialized
✓ 1 [chromium] › src/tests/visualRegression.spec.ts:28:1 › Registrations page (9s)
2 [chromium] › src/tests/visualRegression.spec.ts:46:1 › Add Main Registration page
[percy] Encountered snapshot serialization warnings:
[percy] - stylesheet with attributes - [ data-name: axa-fieldset-myaxa ] - was not serialized
[percy] - stylesheet with attributes - [ data-name: axa-radio-myaxa ] - was not serialized
✓ 2 [chromium] › src/tests/visualRegression.spec.ts:46:1 › Add Main Registration page (5s)
...
how can I rid of this second warning?
Hey @branislav-remen glad this is fixed for you.
we store Github releases in a file located at node_modules/@percy/cli/.releases
(for Unix), I had forgotten to draft a release yesterday, just remove this cache file, and it will not show this warning message.
rm node_modules/@percy/cli/.releases
As part of v1.19.1-alpha.0 release we'd added this serialization warning message, currently there is no way via a flag to disable this warning message.
I'm closing this issue as the original :bug: is fixed, please feel free to open another issue/discussion thread if you face any problems, and thanks for reporting the bug 😄 !
The problem
After last update of
@percy/cli
I get errorpage.evaluate: TypeError: Cannot read properties of null (reading 'sheet') at serializeCSSOM
when runningpercy exec ...
script.Environment
@percy/cli
version: 1.19.0-alpha.0Details
We are using component library which uses Shadow DOM. After upgrade of your CLI to try Shadow DOM support it is not working. The same code works with previous version of cli 1.17.0.
We are using Playwright test runner. Running playwright test script (without percy exec) works. (
playwright test visualRegression
).Debug logs
Code to reproduce issue
percy.yml:
test script:
"test:percy": "percy exec -- playwright test visualRegression",
Example of test:
Playwright config (I also tried default config and it doesn't work):