Permalink
Browse files

Add TS types for t.snapshot(content, options)

  • Loading branch information...
ajafff authored and novemberborn committed Jan 8, 2018
1 parent c1faf95 commit 29e5dfdc55dd9c5f80a24c0276f3362cc167c3a0
Showing with 4 additions and 0 deletions.
  1. +4 −0 types/base.d.ts
View
@@ -7,6 +7,9 @@ export type ErrorValidator
export interface Observable {
subscribe(observer: (value: {}) => void): void;
}
export interface SnapshotOptions {
id?: string;
}
export type Test = (t: TestContext) => PromiseLike<void> | Iterator<any> | Observable | void;
export type GenericTest<T> = (t: GenericTestContext<T>) => PromiseLike<void> | Iterator<any> | Observable | void;
export type CallbackTest = (t: CallbackTestContext) => void;
@@ -78,6 +81,7 @@ export interface AssertContext {
* Assert that contents matches a snapshot.
*/
snapshot(contents: any, message?: string): void;
snapshot(contents: any, options: SnapshotOptions, message?: string): void;
/**
* Assert that contents does not match regex.
*/

0 comments on commit 29e5dfd

Please sign in to comment.