mirror of
https://github.com/rkd77/elinks.git
synced 2025-02-02 15:09:23 -05:00
[test] fragment.hasChildNodes
This commit is contained in:
parent
4bc626acb6
commit
9597051fcc
25
test/js/assert/fragment.hasChildNodes.html
Normal file
25
test/js/assert/fragment.hasChildNodes.html
Normal file
@ -0,0 +1,25 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<body>
|
||||
|
||||
<ul id="myList">
|
||||
<li>Coffee</li>
|
||||
<li>Tea</li>
|
||||
</ul>
|
||||
|
||||
<script>
|
||||
function myFunction() {
|
||||
var ab = document.createDocumentFragment();
|
||||
console.assert(!ab.hasChildNodes(), 'no child nodes');
|
||||
var bc = document.createElement('li');
|
||||
ab.appendChild(bc);
|
||||
console.assert(ab.hasChildNodes(), 'has child nodes');
|
||||
}
|
||||
|
||||
console.error('fragment.hasChildNodes.html');
|
||||
myFunction();
|
||||
console.exit();
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -76,6 +76,7 @@ took = [
|
||||
'fetch.html',
|
||||
'fragment.appendChild.html',
|
||||
'fragment.getElementsByTagName.html',
|
||||
'fragment.hasChildNodes.html',
|
||||
'keyboardEvent.html',
|
||||
'navigator.appCodeName.html',
|
||||
'node.nodeType.html',
|
||||
|
Loading…
x
Reference in New Issue
Block a user