This test checks that :focus-visible doesn't math on ShadowRoot.

  1. The input should be focused on load, if it's not focused, focus it via mouse or keyboard.
  2. If you see no red the test result is SUCCESS.

Your user-agent does not support :focus-visible pseudo-class, please SKIP this test.

Summary

Harness status: OK

Found 2 tests

Details

ResultTest NameMessage
Pass":focus-visible" should be a valid selector
Asserts run
Pass
assert_true(true, "\":focus-visible\" should not throw in querySelector")
    at Test.<anonymous> ( /css/support/parsing-testcommon.js:68:9)
Pass
assert_equals(0, 0, "Sheet should have no rule")
    at Test.<anonymous> ( /css/support/parsing-testcommon.js:76:9)
Pass
assert_equals(1, 1, "Sheet should have 1 rule")
    at Test.<anonymous> ( /css/support/parsing-testcommon.js:78:9)
Pass
assert_equals(":focus-visible", ":focus-visible", "serialization should be canonical")
    at Test.<anonymous> ( /css/support/parsing-testcommon.js:84:13)
Pass
assert_equals(0, 0, "Sheet should have no rule")
    at Test.<anonymous> ( /css/support/parsing-testcommon.js:87:9)
Pass
assert_equals(1, 1, "Sheet should have 1 rule")
    at Test.<anonymous> ( /css/support/parsing-testcommon.js:89:9)
Pass
assert_equals(":focus-visible", ":focus-visible", "serialization should round-trip")
    at Test.<anonymous> ( /css/support/parsing-testcommon.js:91:9)
Pass
assert_equals(true, true, "CSS.supports() reports the expected value")
    at Test.<anonymous> ( /css/support/parsing-testcommon.js:94:9)
Pass:focus-visible doesn't match on ShadowRoot
Asserts run
Pass
assert_not_equals("rgba(0, 0, 0, 0)", "rgb(255, 0, 0)", "backgroundColor for DIV#host should NOT be red")
    at Test.<anonymous> ( /css/selectors/focus-visible-020.html:50:7)
Pass
assert_equals(0, 0, "No element matches ':focus-visible'")
    at Test.<anonymous> ( /css/selectors/focus-visible-020.html:53:7)
Pass
assert_equals(1, 1, "Only one element matches ':focus-visible' in the Shadow DOM")
    at Test.<anonymous> ( /css/selectors/focus-visible-020.html:56:7)
Pass
assert_equals