document.test3b, img);
  assert_equals(document['test3b'], img);
}, "Dynamically removing the id attribute from img elements, should still be accessible by name value.");

test(function() {
  let img = document.getElementsByTagName("img")[4];
  assert_equals(document.test4a, img);
  assert_equals(document['test4a'], img);
  assert_equals(document.test4b, img);
  assert_equals(document['test4b'], img);

  img.name = 'test4a';
  assert_equals(document.test4a, img);
  assert_equals(document['test4a'], img);
  