Bug 1510062 [wpt PR 14241] - CSS: WPTs for CSS Fragmentation parsing, a=testonly

Automatic update from web-platform-tests
CSS: WPTs for CSS Fragmentation parsing

Test parsing, serialiation and computed values for properties defined
in CSS Fragmentation Module Level 3
https://drafts.csswg.org/css-break/

Blink has expected failures for keywords relating to CSS Regions.

Change-Id: Ie5a930ba2d805c7bd45aa84c293bc8ff5922da98
Reviewed-on: https://chromium-review.googlesource.com/c/1351190
Commit-Queue: Emil A Eklund <eae@chromium.org>
Reviewed-by: Emil A Eklund <eae@chromium.org>
Cr-Commit-Position: refs/heads/master@{#611257}

--

wpt-commits: 0c4e091a927fad0091080926e02c8725add704b6
wpt-pr: 14241
This commit is contained in:
Eric Willigers 2018-11-30 18:04:30 +00:00 коммит произвёл moz-wptsync-bot
Родитель 72f4ea42d9
Коммит 0f356b8c94
18 изменённых файлов: 388 добавлений и 0 удалений

Просмотреть файл

@ -0,0 +1,19 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: getComputedValue().boxDecorationBreak</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-box-decoration-break">
<meta name="assert" content="box-decoration-break computed value is as specified.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/computed-testcommon.js"></script>
</head>
<body>
<div id="target"></div>
<script>
test_computed_value("box-decoration-break", "slice");
test_computed_value("box-decoration-break", "clone");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing box-decoration-break with invalid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-box-decoration-break">
<meta name="assert" content="box-decoration-break supports only the grammar 'slice | clone'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_invalid_value("box-decoration-break", "auto");
test_invalid_value("box-decoration-break", "slice clone");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing box-decoration-break with valid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-box-decoration-break">
<meta name="assert" content="box-decoration-break supports the full grammar 'slice | clone'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_valid_value("box-decoration-break", "slice");
test_valid_value("box-decoration-break", "clone");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,29 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: getComputedValue().breakAfter</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-break-after">
<meta name="assert" content="break-after computed value is as specified.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/computed-testcommon.js"></script>
</head>
<body>
<div id="target"></div>
<script>
test_computed_value("break-after", "auto");
test_computed_value("break-after", "avoid");
test_computed_value("break-after", "avoid-page");
test_computed_value("break-after", "page");
test_computed_value("break-after", "left");
test_computed_value("break-after", "right");
test_computed_value("break-after", "recto");
test_computed_value("break-after", "verso");
test_computed_value("break-after", "avoid-column");
test_computed_value("break-after", "column");
test_computed_value("break-after", "avoid-region");
test_computed_value("break-after", "region");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing break-after with invalid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-break-after">
<meta name="assert" content="break-after supports only the grammar 'auto | avoid | avoid-page | page | left | right | recto | verso | avoid-column | column | avoid-region | region'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_invalid_value("break-after", "none");
test_invalid_value("break-after", "avoid region");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,28 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing break-after with valid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-break-after">
<meta name="assert" content="break-after supports the full grammar 'auto | avoid | avoid-page | page | left | right | recto | verso | avoid-column | column | avoid-region | region'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_valid_value("break-after", "auto");
test_valid_value("break-after", "avoid");
test_valid_value("break-after", "avoid-page");
test_valid_value("break-after", "page");
test_valid_value("break-after", "left");
test_valid_value("break-after", "right");
test_valid_value("break-after", "recto");
test_valid_value("break-after", "verso");
test_valid_value("break-after", "avoid-column");
test_valid_value("break-after", "column");
test_valid_value("break-after", "avoid-region");
test_valid_value("break-after", "region");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,29 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: getComputedValue().breakBefore</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-break-before">
<meta name="assert" content="break-before computed value is as specified.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/computed-testcommon.js"></script>
</head>
<body>
<div id="target"></div>
<script>
test_computed_value("break-before", "auto");
test_computed_value("break-before", "avoid");
test_computed_value("break-before", "avoid-page");
test_computed_value("break-before", "page");
test_computed_value("break-before", "left");
test_computed_value("break-before", "right");
test_computed_value("break-before", "recto");
test_computed_value("break-before", "verso");
test_computed_value("break-before", "avoid-column");
test_computed_value("break-before", "column");
test_computed_value("break-before", "avoid-region");
test_computed_value("break-before", "region");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing break-before with invalid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-break-before">
<meta name="assert" content="break-before supports only the grammar 'auto | avoid | avoid-page | page | left | right | recto | verso | avoid-column | column | avoid-region | region'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_invalid_value("break-before", "none");
test_invalid_value("break-before", "avoid region");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,28 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing break-before with valid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-break-before">
<meta name="assert" content="break-before supports the full grammar 'auto | avoid | avoid-page | page | left | right | recto | verso | avoid-column | column | avoid-region | region'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_valid_value("break-before", "auto");
test_valid_value("break-before", "avoid");
test_valid_value("break-before", "avoid-page");
test_valid_value("break-before", "page");
test_valid_value("break-before", "left");
test_valid_value("break-before", "right");
test_valid_value("break-before", "recto");
test_valid_value("break-before", "verso");
test_valid_value("break-before", "avoid-column");
test_valid_value("break-before", "column");
test_valid_value("break-before", "avoid-region");
test_valid_value("break-before", "region");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: getComputedValue().breakAfter</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-break-inside">
<meta name="assert" content="break-inside computed value is as specified.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/computed-testcommon.js"></script>
</head>
<body>
<div id="target"></div>
<script>
test_computed_value("break-inside", "auto");
test_computed_value("break-inside", "avoid");
test_computed_value("break-inside", "avoid-page");
test_computed_value("break-inside", "avoid-column");
test_computed_value("break-inside", "avoid-region");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing break-inside with invalid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-break-inside">
<meta name="assert" content="break-inside supports only the grammar 'auto | avoid | avoid-page | avoid-column | avoid-region'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_invalid_value("break-inside", "region");
test_invalid_value("break-inside", "auto avoid");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing break-inside with valid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-break-inside">
<meta name="assert" content="break-inside supports the full grammar 'auto | avoid | avoid-page | avoid-column | avoid-region'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_valid_value("break-inside", "auto");
test_valid_value("break-inside", "avoid");
test_valid_value("break-inside", "avoid-page");
test_valid_value("break-inside", "avoid-column");
test_valid_value("break-inside", "avoid-region");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,20 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: getComputedValue().orphans</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-orphans">
<meta name="assert" content="orphans computed value is specified integer.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/computed-testcommon.js"></script>
</head>
<body>
<div id="target"></div>
<script>
test_computed_value("orphans", "1");
test_computed_value("orphans", "234");
test_computed_value("orphans", "calc(1 + 234)", "235");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing orphans with invalid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-orphans">
<meta name="assert" content="orphans supports only the grammar '<integer>'.">
<meta name="assert" content="Negative values and zero are invalid.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_invalid_value("orphans", "auto");
test_invalid_value("orphans", "1 234");
test_invalid_value("orphans", "-234");
test_invalid_value("orphans", "-1");
test_invalid_value("orphans", "0");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,19 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing orphans with valid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-orphans">
<meta name="assert" content="orphans supports the full grammar '<integer>'.">
<meta name="assert" content="Negative values and zero are invalid.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_valid_value("orphans", "1");
test_valid_value("orphans", "234");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,20 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: getComputedValue().widows</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-widows">
<meta name="assert" content="widows computed value is specified integer.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/computed-testcommon.js"></script>
</head>
<body>
<div id="target"></div>
<script>
test_computed_value("widows", "1");
test_computed_value("widows", "234");
test_computed_value("widows", "calc(1 + 234)", "235");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing widows with invalid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-widows">
<meta name="assert" content="widows supports only the grammar '<integer>'.">
<meta name="assert" content="Negative values and zero are invalid.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_invalid_value("widows", "auto");
test_invalid_value("widows", "1 234");
test_invalid_value("widows", "-234");
test_invalid_value("widows", "-1");
test_invalid_value("widows", "0");
</script>
</body>
</html>

Просмотреть файл

@ -0,0 +1,19 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Fragmentation Module Level 3: parsing widows with valid values</title>
<link rel="help" href="https://drafts.csswg.org/css-break/#propdef-widows">
<meta name="assert" content="widows supports the full grammar '<integer>'.">
<meta name="assert" content="Negative values and zero are invalid.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
test_valid_value("widows", "1");
test_valid_value("widows", "234");
</script>
</body>
</html>