chromium/third_party/blink/web_tests/fast/dom/shadow/input-shadow-nochange.html

<!DOCTYPE html>
<html>
<head>
<script src="../../../resources/js-test.js"></script>
</head>
<body>
<p>This test checks input's shadow root is not changed if input type is changed.</p>
<pre id="console"></pre>
<div id="container"></div>

<script>
var container = document.getElementById("container");

function doTest() {
    if (!window.testRunner || !window.internals)
        return;

    var input = document.createElement('input');
    var inputTypes = [
        "hidden", "text", "search", "tel", "url", "email", "password", "datetime",
        "date", "month", "week", "time", "datetime-local", "number", "range",
        "color", "checkbox", "radio", "file", "submit", "image", "reset", "button"
    ];

    shadow = internals.shadowRoot(input);
    for (var i = 0; i < inputTypes.length; ++i) {
        input.type = inputTypes[i];

        newShadow = internals.shadowRoot(input);

        debug(inputTypes[i]);
        shouldBe("newShadow", "shadow");
    }
}

doTest();
var successfullyParsed = true;
</script>
</body>
</html>