Skip to content

Commit

Permalink
feature(context): Expose the scheduler.
Browse files Browse the repository at this point in the history
  • Loading branch information
cartant committed Jul 21, 2017
1 parent d81efe1 commit 8774ca1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ interface Context {
flush(): void;
has<T = any>(actual: Observable<T>, expected: string | string[]): void;
hot<T = any>(marbles: string, values?: any, error?: any): HotObservable<T>;
readonly scheduler: TestScheduler;
time(marbles: string): number;
}

Expand Down
6 changes: 6 additions & 0 deletions source/context.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,12 @@ export class Context {
return observable;
}

get scheduler(): TestScheduler {

const { testScheduler } = this;
return testScheduler;
}

time(marbles: string): number {

const { testScheduler } = this;
Expand Down

0 comments on commit 8774ca1

Please sign in to comment.