As per title: I recently started to wright test and in one of the I need to check if the 2 images match. I decided to go with havescreenshot() method to achieve. I need to cut the original snapshot a bit and checked the Wiki for optins and found ** clip option** https://playwright.dev/docs/api/class-pageassertions#page-assertions-to-have-screenshot-1-option-clip I tried to use clip option to set both of them to same size but that option does not exist in the code base. Had it been removed?
This thread is trying to answer question "Has the 'clip' option been removed from the .havescreenshot() method in Playwright?"
Just found a bug on Github for this:
Raised by you?
You can (currently) only use
clip with a page, not a locator
Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email firstname.lastname@example.org.