Improve css parser test coverage

This commit is contained in:
Matthias Clasen 2023-05-12 08:23:56 -04:00
parent a3ebc0329d
commit 09bab2b2df
71 changed files with 202 additions and 0 deletions

View File

@ -0,0 +1,3 @@
* {
font-feature-settings: "";
}

View File

@ -0,0 +1 @@
font-features-invalid1.css:2:26-28: error: GTK_CSS_PARSER_ERROR_UNKNOWN_VALUE

View File

@ -0,0 +1,3 @@
* {
font-feature-settings: "abc\A" 1;
}

View File

@ -0,0 +1 @@
font-features-invalid2.css:2:26-33: error: GTK_CSS_PARSER_ERROR_UNKNOWN_VALUE

View File

@ -0,0 +1,3 @@
* {
font-feature-settings: dlig;
}

View File

@ -0,0 +1 @@
font-features-invalid3.css:2:26-30: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,19 @@
a {
font-feature-settings: initial;
}
b {
font-feature-settings: inherit;
}
c {
font-feature-settings: unset;
}
e {
font-feature-settings: normal;
}
f {
font-feature-settings: "dlig", "c2sc" off, "swsh" 2;
}

View File

@ -0,0 +1,19 @@
a {
font-feature-settings: initial;
}
b {
font-feature-settings: inherit;
}
c {
font-feature-settings: unset;
}
e {
font-feature-settings: normal;
}
f {
font-feature-settings: "dlig" 1, "c2sc" 0, "swsh" 2;
}

View File

@ -342,6 +342,17 @@ test_data = [
'filter-invalid9.ref.css',
'font-family.css',
'font-family.ref.css',
'font-features.css',
'font-features.ref.css',
'font-features-invalid1.css',
'font-features-invalid1.errors',
'font-features-invalid1.ref.css',
'font-features-invalid2.css',
'font-features-invalid2.errors',
'font-features-invalid2.ref.css',
'font-features-invalid3.css',
'font-features-invalid3.errors',
'font-features-invalid3.ref.css',
'font-size.css',
'font-size.ref.css',
'font-stretch.css',
@ -482,6 +493,65 @@ test_data = [
'text-shadow-invalid-but-worked-in-3.12.errors',
'text-shadow-invalid-but-worked-in-3.12.ref.css',
'text-shadow.ref.css',
'transform.css',
'transform.ref.css',
'transform-invalid1.css',
'transform-invalid1.errors',
'transform-invalid1.ref.css',
'transform-invalid2.css',
'transform-invalid2.errors',
'transform-invalid2.ref.css',
'transform-invalid3.css',
'transform-invalid3.errors',
'transform-invalid3.ref.css',
'transform-invalid4.css',
'transform-invalid4.errors',
'transform-invalid4.ref.css',
'transform-invalid5.css',
'transform-invalid5.errors',
'transform-invalid5.ref.css',
'transform-invalid6.css',
'transform-invalid6.errors',
'transform-invalid6.ref.css',
'transform-invalid7.css',
'transform-invalid7.errors',
'transform-invalid7.ref.css',
'transform-invalid8.css',
'transform-invalid8.errors',
'transform-invalid8.ref.css',
'transform-invalid9.css',
'transform-invalid9.errors',
'transform-invalid9.ref.css',
'transform-invalid10.css',
'transform-invalid10.errors',
'transform-invalid10.ref.css',
'transform-invalid11.css',
'transform-invalid11.errors',
'transform-invalid11.ref.css',
'transform-invalid12.css',
'transform-invalid12.errors',
'transform-invalid12.ref.css',
'transform-invalid13.css',
'transform-invalid13.errors',
'transform-invalid13.ref.css',
'transform-invalid14.css',
'transform-invalid14.errors',
'transform-invalid14.ref.css',
'transform-invalid15.css',
'transform-invalid15.errors',
'transform-invalid15.ref.css',
'transform-invalid16.css',
'transform-invalid16.errors',
'transform-invalid16.ref.css',
'transform-invalid17.css',
'transform-invalid17.errors',
'transform-invalid17.ref.css',
'transform-invalid18.css',
'transform-invalid18.errors',
'transform-invalid18.ref.css',
'transform-invalid19.css',
'transform-invalid19.errors',
'transform-invalid19.ref.css',
'transition.css',
'transition-delay.css',
'transition-delay.ref.css',

View File

@ -0,0 +1,3 @@
* {
transform: matrix(1,2,3,4,5);
}

View File

@ -0,0 +1 @@
transform-invalid1.css:2:30-31: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: scaleY(45deg);
}

View File

@ -0,0 +1 @@
transform-invalid10.css:2:21-26: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: scaleZ(45deg);
}

View File

@ -0,0 +1 @@
transform-invalid11.css:2:21-26: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: skew(1,2,3);
}

View File

@ -0,0 +1 @@
transform-invalid12.css:2:19-20: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: skewX(1,2,3);
}

View File

@ -0,0 +1 @@
transform-invalid13.css:2:20-21: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: skewY(1,2,3);
}

View File

@ -0,0 +1 @@
transform-invalid14.css:2:20-21: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: translate(1,2,3);
}

View File

@ -0,0 +1 @@
transform-invalid15.css:2:24-25: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: translate3d(1,2,3);
}

View File

@ -0,0 +1 @@
transform-invalid16.css:2:26-27: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: translateX(1);
}

View File

@ -0,0 +1 @@
transform-invalid17.css:2:25-26: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: translateY(1);
}

View File

@ -0,0 +1 @@
transform-invalid18.css:2:25-26: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: translateZ(1);
}

View File

@ -0,0 +1 @@
transform-invalid19.css:2:25-26: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: matrix3d(1,2,3,4,5,6,7,8,9);
}

View File

@ -0,0 +1 @@
transform-invalid2.css:2:40-41: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: perspective(1,2,3);
}

View File

@ -0,0 +1 @@
transform-invalid3.css:2:26-27: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: rotateZ(1,2,3);
}

View File

@ -0,0 +1 @@
transform-invalid4.css:2:22-23: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: rotateX(2);
}

View File

@ -0,0 +1 @@
transform-invalid5.css:2:22-23: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: rotateY(2);
}

View File

@ -0,0 +1 @@
transform-invalid6.css:2:22-23: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: scale(1,2,3);
}

View File

@ -0,0 +1 @@
transform-invalid7.css:2:23-24: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: scale3d(1,2,3,4,5,6);
}

View File

@ -0,0 +1 @@
transform-invalid8.css:2:27-28: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: scaleX(45deg);
}

View File

@ -0,0 +1 @@
transform-invalid9.css:2:21-26: error: GTK_CSS_PARSER_ERROR_SYNTAX

View File

@ -0,0 +1,3 @@
* {
transform: rotateX(45deg) rotateY(50deg) scale(3,4) translate(1px,2px);
}

View File

@ -0,0 +1,3 @@
* {
transform: rotate3d(1, 0, 0, 45deg) rotate3d(0, 1, 0, 50deg) scale(3, 4) translate3d(1px, 2px, 0);
}