Summary

Harness status: OK

Found 3 tests

Details

ResultTest NameMessage
PassCSSStyleSheet.replaceSync throws NotAllowedError for non-constructed sheets
Asserts run
Pass
assert_equals("rgb(0, 255, 0)", "rgb(0, 255, 0)", "precondition")
    at Test.<anonymous> ( /css/cssom/CSSStyleSheet-constructable-replace-on-regular-sheet.html:15:3)
Pass
assert_throws_dom("NotAllowedError", function "() => sheet.replaceSync(":root { background-color: red }")", "replaceSync on non-constructed sheet should throw")
    at Test.<anonymous> ( /css/cssom/CSSStyleSheet-constructable-replace-on-regular-sheet.html:18:3)
Pass
assert_throws_dom("NotAllowedError", function "() => childSheet.replaceSync(":root { background-color: red }")", "replaceSync on non-constructed sheet should throw")
    at Test.<anonymous> ( /css/cssom/CSSStyleSheet-constructable-replace-on-regular-sheet.html:19:3)
Pass
assert_equals("rgb(0, 255, 0)", "rgb(0, 255, 0)", "old sheet should still apply after replace")
    at Test.<anonymous> ( /css/cssom/CSSStyleSheet-constructable-replace-on-regular-sheet.html:20:3)
PassCSSStyleSheet.replace returns a rejected promise for non-constructed sheets
Asserts run
Pass
assert_equals("rgb(0, 255, 0)", "rgb(0, 255, 0)", "precondition")
    at Test.<anonymous> ( /css/cssom/CSSStyleSheet-constructable-replace-on-regular-sheet.html:24:3)
Pass
assert_equals("rgb(0, 255, 0)", "rgb(0, 255, 0)", "old sheet should still apply after replace")
    at Test.<anonymous> ( /css/cssom/CSSStyleSheet-constructable-replace-on-regular-sheet.html:29:3)
PassCSSStyleSheet.replace returns a rejected promise for non-constructed sheets that have no associated document
Asserts run
Pass
assert_equals("rgb(0, 255, 0)", "rgb(0, 255, 0)", "precondition")
    at Test.<anonymous> ( /css/cssom/CSSStyleSheet-constructable-replace-on-regular-sheet.html:33:3)
Pass
assert_equals("rgba(0, 0, 0, 0)", "rgba(0, 0, 0, 0)", "old sheet was removed, so the default color should apply")
    at Test.<anonymous> ( /css/cssom/CSSStyleSheet-constructable-replace-on-regular-sheet.html:39:3)