summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/css/css-tables/parsing
diff options
context:
space:
mode:
Diffstat (limited to 'testing/web-platform/tests/css/css-tables/parsing')
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/border-collapse-computed.html19
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/border-collapse-invalid.html18
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/border-collapse-valid.html18
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/border-spacing-computed.html26
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/border-spacing-invalid.html20
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/border-spacing-valid.html19
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/caption-side-computed.html19
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/caption-side-invalid.html20
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/caption-side-valid.html18
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/empty-cells-computed.html19
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/empty-cells-invalid.html18
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/empty-cells-valid.html18
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/table-layout-computed.html19
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/table-layout-invalid.html18
-rw-r--r--testing/web-platform/tests/css/css-tables/parsing/table-layout-valid.html18
15 files changed, 287 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/css-tables/parsing/border-collapse-computed.html b/testing/web-platform/tests/css/css-tables/parsing/border-collapse-computed.html
new file mode 100644
index 0000000000..d72cbc6d02
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/border-collapse-computed.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module: getComputedStyle().borderCollapse</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-border-collapse">
+<meta name="assert" content="border-collapse 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("border-collapse", "separate");
+test_computed_value("border-collapse", "collapse");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/border-collapse-invalid.html b/testing/web-platform/tests/css/css-tables/parsing/border-collapse-invalid.html
new file mode 100644
index 0000000000..9b10062f0f
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/border-collapse-invalid.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing border-collapse with invalid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-border-collapse">
+<meta name="assert" content="border-collapse supports only the grammar 'separate | collapse'.">
+<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("border-collapse", "none");
+test_invalid_value("border-collapse", "separate collapse");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/border-collapse-valid.html b/testing/web-platform/tests/css/css-tables/parsing/border-collapse-valid.html
new file mode 100644
index 0000000000..2dc8ae45a3
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/border-collapse-valid.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing border-collapse with valid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-border-collapse">
+<meta name="assert" content="border-collapse supports the full grammar 'separate | collapse'.">
+<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("border-collapse", "separate");
+test_valid_value("border-collapse", "collapse");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/border-spacing-computed.html b/testing/web-platform/tests/css/css-tables/parsing/border-spacing-computed.html
new file mode 100644
index 0000000000..d88acb3bb0
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/border-spacing-computed.html
@@ -0,0 +1,26 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module: getComputedStyle().borderSpacing</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-border-spacing">
+<meta name="assert" content="border-spacing computed value is two absolute lengths.">
+<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>
+<style>
+ #target {
+ font-size: 40px;
+ }
+</style>
+<script>
+test_computed_value("border-spacing", "10px 20px");
+test_computed_value("border-spacing", "0", "0px 0px");
+test_computed_value("border-spacing", "calc(10px + 0.5em) calc(10px - 0.5em)", "30px 0px");
+test_computed_value("border-spacing", "calc(10px - 0.5em) calc(10px + 0.5em)", "0px 30px");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/border-spacing-invalid.html b/testing/web-platform/tests/css/css-tables/parsing/border-spacing-invalid.html
new file mode 100644
index 0000000000..47fd283ccf
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/border-spacing-invalid.html
@@ -0,0 +1,20 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing border-spacing with invalid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-border-spacing">
+<meta name="assert" content="border-spacing supports only the grammar '<length>{1,2}'.">
+<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("border-spacing", "10%");
+test_invalid_value("border-spacing", "-20px");
+test_invalid_value("border-spacing", "30");
+test_invalid_value("border-spacing", "40px 50px 60px");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/border-spacing-valid.html b/testing/web-platform/tests/css/css-tables/parsing/border-spacing-valid.html
new file mode 100644
index 0000000000..cf594ee6b8
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/border-spacing-valid.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing border-spacing with valid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-border-spacing">
+<meta name="assert" content="border-spacing supports the full grammar '<length>{1,2}'.">
+<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("border-spacing", "0px");
+test_valid_value("border-spacing", "10px 20px");
+test_valid_value("border-spacing", "calc(10px + 0.5em) calc(10px - 0.5em)", "calc(0.5em + 10px) calc(-0.5em + 10px)");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/caption-side-computed.html b/testing/web-platform/tests/css/css-tables/parsing/caption-side-computed.html
new file mode 100644
index 0000000000..dc573546af
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/caption-side-computed.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module: getComputedStyle().captionSide</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-caption-side">
+<meta name="assert" content="caption-side 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("caption-side", "top");
+test_computed_value("caption-side", "bottom");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/caption-side-invalid.html b/testing/web-platform/tests/css/css-tables/parsing/caption-side-invalid.html
new file mode 100644
index 0000000000..1552e4d241
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/caption-side-invalid.html
@@ -0,0 +1,20 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing caption-side with invalid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-caption-side">
+<meta name="assert" content="caption-side supports only the grammar 'top | bottom'.">
+<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("caption-side", "auto");
+test_invalid_value("caption-side", "left");
+test_invalid_value("caption-side", "right");
+test_invalid_value("caption-side", "top bottom");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/caption-side-valid.html b/testing/web-platform/tests/css/css-tables/parsing/caption-side-valid.html
new file mode 100644
index 0000000000..a97683a6f4
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/caption-side-valid.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing caption-side with valid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-caption-side">
+<meta name="assert" content="caption-side supports the full grammar 'top | bottom'.">
+<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("caption-side", "top");
+test_valid_value("caption-side", "bottom");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/empty-cells-computed.html b/testing/web-platform/tests/css/css-tables/parsing/empty-cells-computed.html
new file mode 100644
index 0000000000..1a04c0c9f3
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/empty-cells-computed.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module: getComputedStyle().emptyCells</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-empty-cells">
+<meta name="assert" content="empty-cells 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("empty-cells", "show");
+test_computed_value("empty-cells", "hide");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/empty-cells-invalid.html b/testing/web-platform/tests/css/css-tables/parsing/empty-cells-invalid.html
new file mode 100644
index 0000000000..4b5bf95dcd
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/empty-cells-invalid.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing empty-cells with invalid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-empty-cells">
+<meta name="assert" content="empty-cells supports only the grammar 'show | hide'.">
+<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("empty-cells", "auto");
+test_invalid_value("empty-cells", "show hide");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/empty-cells-valid.html b/testing/web-platform/tests/css/css-tables/parsing/empty-cells-valid.html
new file mode 100644
index 0000000000..c3483aafe0
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/empty-cells-valid.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing empty-cells with valid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-empty-cells">
+<meta name="assert" content="empty-cells supports the full grammar 'show | hide'.">
+<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("empty-cells", "show");
+test_valid_value("empty-cells", "hide");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/table-layout-computed.html b/testing/web-platform/tests/css/css-tables/parsing/table-layout-computed.html
new file mode 100644
index 0000000000..3453508541
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/table-layout-computed.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module: getComputedStyle().tableLayout</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-table-layout">
+<meta name="assert" content="table-layout 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("table-layout", "auto");
+test_computed_value("table-layout", "fixed");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/table-layout-invalid.html b/testing/web-platform/tests/css/css-tables/parsing/table-layout-invalid.html
new file mode 100644
index 0000000000..23a60ca56e
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/table-layout-invalid.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing table-layout with invalid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-table-layout">
+<meta name="assert" content="table-layout supports only the grammar 'auto | fixed'.">
+<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("table-layout", "none");
+test_invalid_value("table-layout", "auto fixed");
+</script>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/css-tables/parsing/table-layout-valid.html b/testing/web-platform/tests/css/css-tables/parsing/table-layout-valid.html
new file mode 100644
index 0000000000..bf94ed8369
--- /dev/null
+++ b/testing/web-platform/tests/css/css-tables/parsing/table-layout-valid.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>CSS Table Module Test: parsing table-layout with valid values</title>
+<link rel="help" href="https://drafts.csswg.org/css-tables/#propdef-table-layout">
+<meta name="assert" content="table-layout supports the full grammar 'auto | fixed'.">
+<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("table-layout", "auto");
+test_valid_value("table-layout", "fixed");
+</script>
+</body>
+</html>