Commit 8c53a1c2 authored by Fredrik Söderquist's avatar Fredrik Söderquist Committed by Commit Bot

Fix wpt/css/css-masking/parsing/clip-valid.html subtest

Percentages are not allowed in rect() (arguments are '<length> | auto'.)
Move the old test to clip-invalid.html and replace it with one that
doesn't use percentages.

Bug: 843084
Change-Id: I3cadd99da0d302ac5a0cd012450dd7ade233681c
Reviewed-on: https://chromium-review.googlesource.com/1071469
Commit-Queue: Eric Willigers <ericwilligers@chromium.org>
Reviewed-by: default avatarEric Willigers <ericwilligers@chromium.org>
Cr-Commit-Position: refs/heads/master@{#561598}
parent 1591ea17
......@@ -14,6 +14,7 @@
<script>
test_invalid_value("clip", "none");
test_invalid_value("clip", "rect(10px, 20px, 30px)");
test_invalid_value("clip", "rect(10%, -20%, auto, auto)");
</script>
</body>
</html>
This is a testharness.js-based test.
PASS e.style['clip'] = "auto" should set the property value
PASS e.style['clip'] = "rect(10px, 20px, -30px, 40px)" should set the property value
FAIL e.style['clip'] = "rect(10%, -20%, auto, auto)" should set the property value assert_not_equals: property should be set got disallowed value ""
Harness: the test ran to completion.
......@@ -14,7 +14,7 @@
<script>
test_valid_value("clip", "auto");
test_valid_value("clip", "rect(10px, 20px, -30px, 40px)", ["rect(10px, 20px, -30px, 40px)", "rect(10px 20px -30px 40px)"]);
test_valid_value("clip", "rect(10%, -20%, auto, auto)");
test_valid_value("clip", "rect(10px, -20px, auto, auto)", ["rect(10px, -20px, auto, auto)", "rect(10px -20px auto auto)"]);
</script>
</body>
</html>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment