DefinitelyTyped/types/mitsobox/mitsobox-tests.ts
Clément PONT a5bc0a0874 Add mitsobox (#41121)
* Add mitsobox

* Apply correction requested by andrewbranch
2019-12-26 10:20:40 -06:00

14 lines
774 B
TypeScript

import { ok, okCancel, abortRetryIgnore } from 'mitsobox';
// tslint:disable-next-line: no-duplicate-imports
import * as mitsobox from 'mitsobox';
// member import tests
ok('test - ok', 'a test messageBox'); // $ExpectType Promise<void>
okCancel('test - okCancel', 'a test messageBox'); // $ExpectType Promise<"OK" | "CANCEL">
abortRetryIgnore('test - abortRetryIgnore', 'a test messageBox'); // $ExpectType Promise<"ABORT" | "RETRY" | "IGNORE">
// module import tests
mitsobox.ok('test - ok', 'a test messageBox'); // $ExpectType Promise<void>
mitsobox.okCancel('test - okCancel', 'a test messageBox'); // $ExpectType Promise<"OK" | "CANCEL">
mitsobox.abortRetryIgnore('test - abortRetryIgnore', 'a test messageBox'); // $ExpectType Promise<"ABORT" | "RETRY" | "IGNORE">