function assertButtons(keys) {
  const buttons = dom.getElementsByTagName(TagName.BUTTON, dialog.getElement());
  const actualKeys = [];
  for (let i = 0; i < buttons.length; i++) {
    actualKeys[i] = buttons[i].name;
  }
  assertArrayEquals(keys, actualKeys);
}
Assert that the dialog has buttons with the given keys in the correct
order.
@param {Array<string>} keys An array of button keys.