Source code
Revision control
Copy as Markdown
Other Tools
Test Info: Warnings
- This test has a WPT meta file that expects 44 subtest issues.
- This WPT test may be referenced by the following Test IDs:
- /css/css-gaps/parsing/gap-decorations-color-valid.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Gap Decorations: parsing column-rule-color with valid values</title>
<link rel="author" title="Sam Davis Omekara Jr." href="mailto:samomekarajr@microsoft.com">
<meta name="assert" content="column-rule-color supports the full grammar '[ <line-color-list> | <auto-line-color-list> ]'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
const properties = ["column-rule-color", "row-rule-color", "rule-color"];
for (let property of properties) {
// <repeat-line-color> = repeat( [ <integer [1,∞]> ] , [ <color> ]+ )
test_valid_value(property, "repeat(4, blue)");
test_valid_value(property, "repeat(3, red green blue)");
test_valid_value(property, "repeat(1, red green blue yellow)");
// <line-color-or-repeat> = [ <color> | <repeat-line-color> ]
test_valid_value(property, "red");
test_valid_value(property, "repeat(4, cyan)");
// <line-color-list> = [ <line-color-or-repeat> ]+
test_valid_value(property, "green blue");
test_valid_value(property, "red blue green yellow pink");
test_valid_value(property, "repeat(3, blue) repeat(4, red)");
test_valid_value(property, "red repeat(3, blue) blue repeat(4, red green cyan)");
test_valid_value(property, "repeat(4, red green cyan) repeat(5, yellow) blue");
// <auto-repeat-line-color> = repeat( auto , [ <color> ]+ )
test_valid_value(property, "repeat(auto, red)");
test_valid_value(property, "repeat(auto, red green blue)");
// <auto-line-color-list> = [ <line-color-or-repeat> ]*
// <auto-repeat-line-color>
// [ <line-color-or-repeat> ]*
test_valid_value(property, "repeat(auto, red green) red");
test_valid_value(property, "repeat(4, blue red green) repeat(auto, red)");
test_valid_value(property, "blue repeat(auto, red green) repeat(4, blue red green)");
}
</script>
</body>
</html>