2 <title>Test for custom content inheritance
</title>
4 html { color: red !important; }
6 <script src=
"/tests/SimpleTest/SimpleTest.js"></script>
9 let doc
= SpecialPowers
.wrap(document
);
10 let div
= doc
.createElement('div');
12 ok(!!doc
.insertAnonymousContent
,
13 "Must have the insertAnonymousContent API");
14 let content
= doc
.insertAnonymousContent();
15 ok(!!content
, "Must have anon content");
16 content
.root
.appendChild(div
);
17 let color
= SpecialPowers
.wrap(window
).getComputedStyle(div
).color
;
18 ok(!!color
, "Should be able to get a color");
19 isnot(color
, getComputedStyle(document
.documentElement
).color
,
20 "Custom anon content shouldn't inherit from the root element");
23 SimpleTest
.waitForExplicitFinish();