blob: b972f0209dedfbeec18b3a18a500f3161a1f9463 [file] [log] [blame]
<!DOCTYPE html>
<html>
<body>
<script src="../../resources/js-test-pre.js"></script>
<script>
description("The 'length' property on interfaces objects should have attributes { [[Writable]]: false, [[Enumerable]]: false, [[Configurable]]: true }.");
debug("* Event");
var descriptor = Object.getOwnPropertyDescriptor(Event, "length");
shouldBeFalse("descriptor.writable");
shouldBeFalse("descriptor.enumerable");
shouldBeTrue("descriptor.configurable");
shouldBe("descriptor.value", "1");
debug("* Element");
var descriptor = Object.getOwnPropertyDescriptor(Element, "length");
shouldBeFalse("descriptor.writable");
shouldBeFalse("descriptor.enumerable");
shouldBeTrue("descriptor.configurable");
shouldBe("descriptor.value", "0");
debug("* Document");
var descriptor = Object.getOwnPropertyDescriptor(Document, "length");
shouldBeFalse("descriptor.writable");
shouldBeFalse("descriptor.enumerable");
shouldBeTrue("descriptor.configurable");
shouldBe("descriptor.value", "0");
debug("* Window");
var descriptor = Object.getOwnPropertyDescriptor(Window, "length");
shouldBeFalse("descriptor.writable");
shouldBeFalse("descriptor.enumerable");
shouldBeTrue("descriptor.configurable");
shouldBe("descriptor.value", "0");
debug("* HTMLOptionElement");
var descriptor = Object.getOwnPropertyDescriptor(HTMLOptionElement, "length");
shouldBeFalse("descriptor.writable");
shouldBeFalse("descriptor.enumerable");
shouldBeTrue("descriptor.configurable");
shouldBe("descriptor.value", "0");
debug("* Option");
var descriptor = Object.getOwnPropertyDescriptor(Option, "length");
shouldBeFalse("descriptor.writable");
shouldBeFalse("descriptor.enumerable");
shouldBeTrue("descriptor.configurable");
shouldBe("descriptor.value", "0");
</script>
<script src="../../resources/js-test-post.js"></script>
</body>
</html>