-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: Can't use radio value with .toMatchSnapshot() since Playwright 1.50.0 #34633
Comments
@mduivcap Thank you for your feedback, we really appreciate you using this new feature and sharing your thoughts! There was a bugfix in #33941. The reason is that checkbox/radio values are not actually visible to the user and do not belong to the ARIA tree. Unfortunately, that broke your particular snapshot, so you'll have to rebase it. You can probably expect a few more small fixes like that - we are trying to minimize the impact while fixing all the oversights based on the customers' feedback. Again, please share more feedback for this feature, we'd love to hear it! |
I think this particular thing will be a quick fix. (just remove the values from the test). My view (since you asked for it) is that I like having multiple options so I can see what works best for my situation to validate something. In the example above it does not matter, I could leave out the value. |
@mduivcap Thank you for sharing your perspective. Playwright is providing various tools, many of them operate on non-user-visible values. However, aria snapshot is supposed to follow the accessibility standards, and those usually only include visible text, although not always. Anyway, closing this issue since there is no action planned. Thank you for filing! |
I once had to write tests for a website that wanted to reuse all test on all language variantions of the site (since this also tested if the SAP implementation worked etc). So I always have this example in mind when I create tests. Now I could also add some layers in the test framework to cover all translations for all elements, OR I could leave out that complexity and just deal with different selectors and validations. So that is always on my mind with these kind of discussions. No wrong/right (as long as the test does what it's suppose to do), but I like simplicity in my test framework when possible. So this is always on my mind in these discussions. |
Version
1.50.1
Steps to reproduce
Example test
Expected behavior
With version 1.49.1 I could use the value of the radio button like the example above
- radio "Geen periodefilter" [checked]: periodFilter.none
Actual behavior
Since I updated to version 1.50.0 or 1.50.1 the test fails because of the value
: periodFilter.none
.If I remove this part, the test passes again.
- radio "Geen periodefilter" [checked]
Additional context
Environment
The text was updated successfully, but these errors were encountered: