1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/layout/reftests/dom/xbl-children-4.xhtml Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,29 @@ 1.4 +<!DOCTYPE html> 1.5 +<html xmlns="http://www.w3.org/1999/xhtml" 1.6 + xmlns:xbl="http://www.mozilla.org/xbl" 1.7 + class="reftest-wait"> 1.8 +<head> 1.9 + <meta charset="UTF-8" /> 1.10 + <style> 1.11 + children { display:block; } 1.12 + </style> 1.13 +</head> 1.14 +<body> 1.15 + <xbl:children /> 1.16 + <script> 1.17 + onload = function() { 1.18 + /* First, schedule a pending restyle of the whole tree. */ 1.19 + var newSheet = document.createElementNS("http://www.w3.org/1999/xhtml", "style"); 1.20 + newSheet.appendChild(document.createTextNode("#nosuchelement { }")); 1.21 + document.head.appendChild(newSheet); 1.22 + 1.23 + /* Now, append a frame to our children element, causing the pending restyle to descend into it. */ 1.24 + var children = document.getElementsByTagName("xbl:children")[0]; 1.25 + var span = document.createElementNS("http://www.w3.org/1999/xhtml", "span"); 1.26 + span.appendChild(document.createTextNode("PASS")); 1.27 + children.appendChild(span); 1.28 + document.documentElement.removeAttribute("class"); 1.29 + } 1.30 + </script> 1.31 +</body> 1.32 +</html>