Status: FAIL | Duration: 45ms | Subtests: 1/2 | Open test on wpt.live | wpt.fyi
Data from commit:
a50cb89 wpt: run reference-named files which are themselves tests (#836) (2026-09-03)
| Subtest | Status | Message |
|---|---|---|
| A stylesheet may be imported multiple times, and scoped differently | FAIL | assert_equals: expected "1" but got "" |
| Scope-imported rule does not apply outside of scope | PASS |
/css/css-cascade/scope-import-multiple.html
<!DOCTYPE html> <title>@import scope(), same stylesheet imported multiple times</title> <link rel="help" href="https://drafts.csswg.org/css-cascade-6/#at-import"> <script src="/resources/testharness.js"></script> <script src="/resources/testharnessreport.js"></script> <style> @import url("resources/scope-imported.css") scope((.scope1)); @import url("resources/scope-imported.css") scope((.scope2)); </style> <main id=main> <div class=scope1> <div class=x>Inside</div> </div> <div class=scope2> <div class=x>Inside</div> </div> <div class=x>Outside</div> </main> <script> test(() => { let e1 = main.querySelector('.scope1 > .x'); let e2 = main.querySelector('.scope2 > .x'); assert_equals(getComputedStyle(e1).getPropertyValue('--x'), '1'); assert_equals(getComputedStyle(e2).getPropertyValue('--x'), '1'); }, 'A stylesheet may be imported multiple times, and scoped differently'); test(() => { let e = main.querySelector('main > .x'); assert_equals(getComputedStyle(e).getPropertyValue('--x'), ''); }, 'Scope-imported rule does not apply outside of scope'); </script>