<!DOCTYPE html>
<body>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<form>
<img name="imageName">
<img id="imageId">
</form>
<script>
test(function() {
var collection = document.querySelector('form').elements;
assert_equals(collection['imageName'], undefined, 'name getter for name=');
assert_equals(collection['imageId'], undefined, 'name getter for id=');
assert_equals(collection.namedItem('imageName'), null);
assert_equals(collection.namedItem('imageId'), null);
for (var i = 0; i < collection.length; ++i)
assert_not_equals(collection[i].tagName, 'IMG');
}, 'HTMLFormControlsCollection should not handle IMG elements.');
</script>
</body>