mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-08 18:46:03 +00:00
Tests: Add a test for @supports
This is derived from our old demo page. Notably, we currently do claim to support `::-webkit-foo` selectors, which is a bug. According to the spec [1], we have to parse those as valid, but `@supports` should still fail for them [2], which is a bit confusing. [1] https://www.w3.org/TR/selectors-4/#compat [2] https://drafts.csswg.org/css-conditional-4/#support-definition-ext
This commit is contained in:
parent
398e112c8c
commit
a9a25d4eca
Notes:
github-actions[bot]
2024-11-07 14:13:15 +00:00
Author: https://github.com/AtkinsSJ
Commit: a9a25d4eca
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2202
2 changed files with 64 additions and 0 deletions
17
Tests/LibWeb/Text/expected/css/supports.txt
Normal file
17
Tests/LibWeb/Text/expected/css/supports.txt
Normal file
|
@ -0,0 +1,17 @@
|
|||
These should all pass:
|
||||
@supports (color: green): PASS
|
||||
@supports (color: green) and (width: 50px): PASS
|
||||
@supports (color: green) or (flogwizzle: purple): PASS
|
||||
@supports (not (flogwizzle: purple)): PASS
|
||||
@supports selector(.simple): PASS
|
||||
@supports selector(a#more > .complicated.case:nth-child(42)): PASS
|
||||
@supports selector(.easy) or selector(.....nope): PASS
|
||||
|
||||
These should all fail:
|
||||
@supports (not (color: green)): FAIL
|
||||
@supports (color: green) and (width: 50px) or (color: green): FAIL
|
||||
@supports (width: yellow) or (height: green): FAIL
|
||||
@supports (flogwizzle: purple): FAIL
|
||||
@supports selector(.....nope): FAIL
|
||||
@supports selector(::-webkit-input-placeholder): PASS
|
||||
@supports selector(32) or selector(thing[foo??????bar]): FAIL
|
Loading…
Add table
Add a link
Reference in a new issue