blob: db04fae4cfd4831bc663d4bcb2e5fb6f8c6040ab [file] [log] [blame]
<!DOCTYPE html>
<body>
<script src="../../../resources/js-test.js"></script>
<div id=container>
<template><div></div></template>
</div>
<script>
description('Test that cycle detection traverses over both templates and shadow roots');
var outerDiv = document.getElementById('container');
var template = document.querySelector('template');
var div = template.content.firstChild;
var shadowRoot = div.attachShadow({mode: 'open'});
var shadowDiv = shadowRoot.appendChild(document.createElement('div'));
shouldThrow('shadowDiv.appendChild(outerDiv)');
</script>
</body>