about summary refs log blame commit diff stats
path: root/test/js/documentall.html
blob: 14db9d70dbaffb8414caeb0a9f466383005ec5dc (plain) (tree)


















                                                                         
<!doctype html>
<title>HTMLCollection test</title>
<div id="result">Fail</div>
<style>style 1</style>
<style>style 2</style>
<style>style 3</style>
<script>
(function() {
	const abc = document.all;
	if (document.all || abc) return; /* document.all must be falsy */
	if (abc.length !== 9) return;
	const styles = [abc[5], abc[6], abc[7]];
	if (styles[0].textContent !== "style 1") return;
	if (styles[1].textContent !== "style 2") return;
	if (styles[2].textContent !== "style 3") return;
	const result = document.getElementById("result");
	result.textContent = "Success";
})()
</script>