mirror of
https://github.com/Foundry376/Mailspring.git
synced 2024-11-14 13:44:41 +08:00
b29d5ac75b
Summary: Adding tests Test Plan: Tests Reviewers: juan, bengotow Reviewed By: bengotow Differential Revision: https://phab.nylas.com/D2892
17 lines
460 B
JavaScript
17 lines
460 B
JavaScript
// import Rx from 'rx-lite-testing'
|
|
import {events} from './fixtures/events'
|
|
import {CalendarDataSource} from 'nylas-exports'
|
|
|
|
export default class TestDataSource extends CalendarDataSource {
|
|
buildObservable({startTime, endTime}) {
|
|
this.endTime = endTime;
|
|
this.startTime = startTime;
|
|
return this
|
|
}
|
|
|
|
subscribe(onNext) {
|
|
onNext({events})
|
|
this.unsubscribe = jasmine.createSpy("unusbscribe");
|
|
return {dispose: this.unsubscribe}
|
|
}
|
|
}
|