function setBoundingClientRect(target, {x, y, width, height}) {
  target.getBoundingClientRect = function () {
    return {
      width,
      height,
      left: x,
      right: x + width,
      top: y,
      bottom: y + height,
    };
  };
}
Stub out getBoundingClientRect for the specified target.
This API is required by the test selectors but it isn't implemented by jsdom.