chromium/third_party/blink/web_tests/fast/dom/Element/setAttributeNode-for-existing-attribute.html

<!DOCTYPE html>
<html>
<head>
<script>
function runTest() {
    if (window.testRunner)
        testRunner.dumpAsText();
        
    var testElement = document.getElementById('test');
    var testElementBgColor = testElement.style.backgroundColor;
    
    var newAttr = document.createAttribute("STYLE");
    newAttr.value = "background-color: green";
    testElement.setAttributeNode(newAttr);
    var testElementBgColorAfterReset = testElement.style.backgroundColor;
    
    document.getElementById('result').innerHTML = "background-color specified with lowercase style attribute was: "+testElementBgColor+" and specified with uppercase style attribute is: "+testElementBgColorAfterReset;
}
</script>
</head>
<body onload="runTest();">
<div>Testcase for bug <a href="http://crbug.com/279193">279193</a>: setAttributeNode() does not set the new value to an existing attribute if specified attribute is in a different case.\nThe issue can be manually verified by ascertaining that a green colored block is displayed instead of a red one.</div>
<div id="test" style="background-color: red;"/>&nbsp;</div>
<div id="result"></div>
</body>
</html>