forked from AuroraMiddleware/gtk
tests: Add a test to ensure we handle unknown pseudo-classes correctly
1) We want to throw an unknown value 2) We want to skip the whole rule
This commit is contained in:
parent
e7aa125eb0
commit
174cfff50f
@ -68,6 +68,9 @@ EXTRA_DIST += \
|
||||
integer.ref.css \
|
||||
no-semicolon.css \
|
||||
no-semicolon.ref.css \
|
||||
pseudo-classes-unknown.css \
|
||||
pseudo-classes-unknown.errors \
|
||||
pseudo-classes-unknown.ref.css \
|
||||
selector.css \
|
||||
selector.ref.css \
|
||||
simple.css
|
||||
|
23
tests/css/parser/pseudo-classes-unknown.css
Normal file
23
tests/css/parser/pseudo-classes-unknown.css
Normal file
@ -0,0 +1,23 @@
|
||||
:nobody-knows-me {
|
||||
int-property: 42;
|
||||
}
|
||||
|
||||
:nobody-knows-me(really) {
|
||||
int-property: 42;
|
||||
}
|
||||
|
||||
:a:lot:of:unkwnown:pseudo:classes(some):of(them):with:functions( spaces ) {
|
||||
int-property: 42;
|
||||
}
|
||||
|
||||
:nth-child {
|
||||
int-property: 42;
|
||||
}
|
||||
|
||||
:nth-child() {
|
||||
int-property: 42;
|
||||
}
|
||||
|
||||
x, :unknown-pseudo-classes-invalidate-selectors, y {
|
||||
int-property: 42;
|
||||
}
|
6
tests/css/parser/pseudo-classes-unknown.errors
Normal file
6
tests/css/parser/pseudo-classes-unknown.errors
Normal file
@ -0,0 +1,6 @@
|
||||
pseudo-classes-unknown.css:1: error: GTK_CSS_PROVIDER_ERROR_UNKNOWN_VALUE
|
||||
pseudo-classes-unknown.css:5: error: GTK_CSS_PROVIDER_ERROR_UNKNOWN_VALUE
|
||||
pseudo-classes-unknown.css:9: error: GTK_CSS_PROVIDER_ERROR_UNKNOWN_VALUE
|
||||
pseudo-classes-unknown.css:13: error: GTK_CSS_PROVIDER_ERROR_UNKNOWN_VALUE
|
||||
pseudo-classes-unknown.css:17: error: GTK_CSS_PROVIDER_ERROR_UNKNOWN_VALUE
|
||||
pseudo-classes-unknown.css:21: error: GTK_CSS_PROVIDER_ERROR_UNKNOWN_VALUE
|
0
tests/css/parser/pseudo-classes-unknown.ref.css
Normal file
0
tests/css/parser/pseudo-classes-unknown.ref.css
Normal file
Loading…
Reference in New Issue
Block a user