Skip to content

Commit

Permalink
feat(testScheduler): subscribeTo() now takes start and stop time as o…
Browse files Browse the repository at this point in the history
…ptional params
  • Loading branch information
tusharmath committed Mar 25, 2018
1 parent b7ceeef commit e7b51ef
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/schedulers/TestScheduler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,11 @@ export class TestScheduler implements IScheduler {
})
}

subscribeTo<T>(f: () => IObservable<T>, start: number, stop: number) {
subscribeTo<T>(
f: () => IObservable<T>,
start: number = DEFAULT_OPTIONS.subscriptionStart,
stop: number = DEFAULT_OPTIONS.subscriptionStop
) {
let subscription: ISubscription
const observer = this.Observer()
this.delay(() => (subscription = f().subscribe(observer, this)), start, 0)
Expand Down

0 comments on commit e7b51ef

Please sign in to comment.