diff options
author | Matt A. Tobin <email@mattatobin.com> | 2020-04-17 07:08:22 -0400 |
---|---|---|
committer | Matt A. Tobin <email@mattatobin.com> | 2020-04-17 07:08:22 -0400 |
commit | 8beb65dd501cbdcfd6a793027b5de2a1fdfc7149 (patch) | |
tree | 4b524fb1a1888b37bc347dc65c7c200979fe54aa /dom/tests/mochitest/webcomponents/test_dynamic_content_element_matching.html | |
parent | 5524318fe73a1123da10491a6a545b50af88ea60 (diff) | |
download | UXP-8beb65dd501cbdcfd6a793027b5de2a1fdfc7149.tar UXP-8beb65dd501cbdcfd6a793027b5de2a1fdfc7149.tar.gz UXP-8beb65dd501cbdcfd6a793027b5de2a1fdfc7149.tar.lz UXP-8beb65dd501cbdcfd6a793027b5de2a1fdfc7149.tar.xz UXP-8beb65dd501cbdcfd6a793027b5de2a1fdfc7149.zip |
Bug 1418002 - Remove HTMLContentElement
Tag #1375
Diffstat (limited to 'dom/tests/mochitest/webcomponents/test_dynamic_content_element_matching.html')
-rw-r--r-- | dom/tests/mochitest/webcomponents/test_dynamic_content_element_matching.html | 50 |
1 files changed, 0 insertions, 50 deletions
diff --git a/dom/tests/mochitest/webcomponents/test_dynamic_content_element_matching.html b/dom/tests/mochitest/webcomponents/test_dynamic_content_element_matching.html deleted file mode 100644 index c9af76610..000000000 --- a/dom/tests/mochitest/webcomponents/test_dynamic_content_element_matching.html +++ /dev/null @@ -1,50 +0,0 @@ -<!DOCTYPE HTML> -<html> -<!-- -https://bugzilla.mozilla.org/show_bug.cgi?id=806506 ---> -<head> - <title>Test for dynamic changes to content matching content elements</title> - <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> - <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" /> -</head> -<body> -<div class="tall" id="bodydiv"></div> -<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=806506">Bug 806506</a> -<script> -// Create ShadowRoot. -var elem = document.createElement("div"); -var root = elem.createShadowRoot(); - -var redInsertionPoint = document.createElement("content"); -redInsertionPoint.select = "*[data-color=red]"; - -var blueInsertionPoint = document.createElement("content"); -blueInsertionPoint.select = "*[data-color=blue]"; - -root.appendChild(redInsertionPoint); -root.appendChild(blueInsertionPoint); - -is(blueInsertionPoint.getDistributedNodes().length, 0, "Blue insertion point should have no distributed nodes."); -is(redInsertionPoint.getDistributedNodes().length, 0, "Red insertion point should have no distrubted nodes."); - -var matchElement = document.createElement("div"); -matchElement.setAttribute("data-color", "red"); -elem.appendChild(matchElement); - -is(blueInsertionPoint.getDistributedNodes().length, 0, "Blue insertion point should have no distributed nodes."); -is(redInsertionPoint.getDistributedNodes().length, 1, "Red insertion point should match recently inserted div."); - -matchElement.setAttribute("data-color", "blue"); -is(blueInsertionPoint.getDistributedNodes().length, 1, "Blue insertion point should match element after changing attribute value."); -is(redInsertionPoint.getDistributedNodes().length, 0, "Red insertion point should not match element after changing attribute value."); - -matchElement.removeAttribute("data-color"); - -is(blueInsertionPoint.getDistributedNodes().length, 0, "Blue insertion point should have no distributed nodes after removing the matching attribute."); -is(redInsertionPoint.getDistributedNodes().length, 0, "Red insertion point should have no distrubted nodes after removing the matching attribute."); - -</script> -</body> -</html> - |