ctorAll("img.png");
  for (let i=0; i<images.length; ++i) {
    images[i].src = pngSrc;
  }

  // SVG with no intrinsic width/height
  let svgSrc="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' %3E%3Crect width='100%' height='100%' style='fill:rgb(0,255,0);'/%3E%3C/svg%3E ";
  images = document.querySelectorAll("img.svg");
  for (let i=0; i<images.length; ++i) {
    images[i].src = svgSrc;
  }

  function makeTest(el) {
    return function() {
      if (!el.getAttribute("data-expected-width"))