1 | 'use strict';
|
2 | var Rx = require(__dirname);
|
3 |
|
4 | var marbleTesting = require('./spec-js/helpers/marble-testing');
|
5 |
|
6 | global.rxTestScheduler = new Rx.TestScheduler(marbleTesting.assertDeepEqual);
|
7 |
|
8 | function it(callback) {
|
9 | callback();
|
10 | }
|
11 |
|
12 | it.asDiagram = function asDiagram() {
|
13 | return function (spec, callback) {
|
14 | callback();
|
15 | }
|
16 | };
|
17 |
|
18 | module.exports = {
|
19 | require: {
|
20 | '@reactivex/rxjs': Rx
|
21 | },
|
22 |
|
23 | globals: {
|
24 | document: {
|
25 | querySelector: function () {
|
26 | return {
|
27 | addEventListener: function () {},
|
28 | removeEventListener: function () {}
|
29 | }
|
30 | }
|
31 | },
|
32 | emptySubs: marbleTesting.emptySubs,
|
33 | hot: marbleTesting.hot,
|
34 | cold: marbleTesting.cold,
|
35 | expectObservable: marbleTesting.expectObservable,
|
36 | expectSubscriptions: marbleTesting.expectSubscriptions,
|
37 | assertDeepEqual: marbleTesting.assertDeepEqual,
|
38 | Rx: Rx,
|
39 | setTimeout: setTimeout,
|
40 | setInterval: setInterval,
|
41 | clearInterval: clearInterval,
|
42 | Observable: Rx.Observable,
|
43 | someObservable: Rx.Observable.range(1, 10),
|
44 | it: it
|
45 | },
|
46 |
|
47 | regexRequire: {
|
48 | 'rxjs/(.*)': function (_, moduleName) {
|
49 | return require(__dirname + '/dist/package/' + moduleName);
|
50 | }
|
51 | },
|
52 |
|
53 | babel: {
|
54 | stage: 0
|
55 | }
|
56 | };
|