testOkPreventDefault() {
    dialog = createTestDialog();
    expectOkPreventDefault(dialog);
    mockCtrl.$replayAll();

    dialog.show();
    events.fireClickSequence(dialog.getOkButtonElement());
    assertOpen(
        'Dialog should not be closed because preventDefault was called',
        dialog);

    mockCtrl.$verifyAll();
  }
Tests that if the OK handler calls preventDefault, the dialog doesn't
     close.
@suppress {checkTypes,visibility} suppression added to enable type checking