Skip to content
Permalink
Browse files

Add `after.always` and `afterEach.always` runners to type definitions (

  • Loading branch information...
rhysd authored and jamestalmage committed May 27, 2016
1 parent c740202 commit 2e984380c4df2bfe5a0af2ec37a970f4001c9f53
Showing with 8 additions and 2 deletions.
  1. +8 −2 index.d.ts
@@ -15,12 +15,18 @@ export interface Runner {
skip: Runner;
cb: CallbackRunner;
}
export interface AfterRunner extends Runner {
always: Runner;
}
export interface ContextualRunner {
(name: string, run: ContextualTest): void;
(run: ContextualTest): void;
skip: ContextualRunner;
cb: ContextualCallbackRunner;
}
export interface ContextualAfterRunner extends ContextualRunner {
always: ContextualRunner;
}
export interface SerialRunner {
(name: string, run: SerialTest): void;
(run: SerialTest): void;
@@ -46,9 +52,9 @@ export function test(name: string, run: ContextualTest): void;
export function test(run: ContextualTest): void;
export namespace test {
export const before: Runner;
export const after: Runner;
export const after: AfterRunner;
export const beforeEach: ContextualRunner;
export const afterEach: ContextualRunner;
export const afterEach: ContextualAfterRunner;

export const skip: typeof test;
export const only: typeof test;

0 comments on commit 2e98438

Please sign in to comment.
You can’t perform that action at this time.