gecko-dev/testing/web-platform/tests/css/css-backgrounds/parsing/background-invalid.html
Cameron McCormack 63106e4aca Bug 1580078 [wpt PR 18952] - Add test for invalid background shorthand <bg-size> position., a=testonly
Automatic update from web-platform-tests
Add test for invalid background shorthand <bg-size> position.

Fixes #18947

--

wpt-commits: 4b106c87a91c6e9875ad59f7cca14216f05b4e0e
wpt-pr: 18952
2019-09-14 08:52:01 +00:00

22 lines
869 B
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Backgrounds and Borders Module Level 3: parsing background with invalid values</title>
<link rel="author" title="Eric Willigers" href="mailto:ericwilligers@chromium.org">
<link rel="help" href="https://drafts.csswg.org/css-backgrounds/#background">
<meta name="assert" content="background supports only the grammar '<bg-layer># , <final-bg-layer>'.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/css/support/parsing-testcommon.js"></script>
</head>
<body>
<script>
// <bg-layer> does not allow a <color>.
test_invalid_value("background", "red, green");
// A `/ <bg-size>` is only allowed directly after a <bg-position>.
test_invalid_value("background", "black 0 url(https://example.invalid/) / cover");
</script>
</body>
</html>