@reactivex/rxjs
Version:
Reactive Extensions for modern JavaScript
1,300 lines (1,299 loc) • 848 kB
JSON
{
"type": "Program",
"body": [
{
"type": "ExpressionStatement",
"expression": {
"type": "Literal",
"value": "use strict",
"raw": "\"use strict\"",
"range": [
0,
12
],
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 1,
"column": 12
}
}
},
"range": [
0,
13
],
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 1,
"column": 13
}
}
},
{
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "Rx",
"range": [
18,
20
],
"loc": {
"start": {
"line": 2,
"column": 4
},
"end": {
"line": 2,
"column": 6
}
}
},
"init": {
"type": "CallExpression",
"callee": {
"type": "Identifier",
"name": "require",
"range": [
23,
30
],
"loc": {
"start": {
"line": 2,
"column": 9
},
"end": {
"line": 2,
"column": 16
}
}
},
"arguments": [
{
"type": "Literal",
"value": "../../dist/cjs/Rx",
"raw": "'../../dist/cjs/Rx'",
"range": [
31,
50
],
"loc": {
"start": {
"line": 2,
"column": 17
},
"end": {
"line": 2,
"column": 36
}
}
}
],
"range": [
23,
51
],
"loc": {
"start": {
"line": 2,
"column": 9
},
"end": {
"line": 2,
"column": 37
}
}
},
"range": [
18,
51
],
"loc": {
"start": {
"line": 2,
"column": 4
},
"end": {
"line": 2,
"column": 37
}
}
}
],
"kind": "var",
"range": [
14,
52
],
"loc": {
"start": {
"line": 2,
"column": 0
},
"end": {
"line": 2,
"column": 38
}
}
},
{
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "Observable",
"range": [
57,
67
],
"loc": {
"start": {
"line": 3,
"column": 4
},
"end": {
"line": 3,
"column": 14
}
}
},
"init": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "Rx",
"range": [
70,
72
],
"loc": {
"start": {
"line": 3,
"column": 17
},
"end": {
"line": 3,
"column": 19
}
}
},
"property": {
"type": "Identifier",
"name": "Observable",
"range": [
73,
83
],
"loc": {
"start": {
"line": 3,
"column": 20
},
"end": {
"line": 3,
"column": 30
}
}
},
"range": [
70,
83
],
"loc": {
"start": {
"line": 3,
"column": 17
},
"end": {
"line": 3,
"column": 30
}
}
},
"range": [
57,
83
],
"loc": {
"start": {
"line": 3,
"column": 4
},
"end": {
"line": 3,
"column": 30
}
}
}
],
"kind": "var",
"range": [
53,
84
],
"loc": {
"start": {
"line": 3,
"column": 0
},
"end": {
"line": 3,
"column": 31
}
},
"trailingComments": [
{
"type": "Block",
"value": "* @test {distinct} ",
"range": [
85,
108
],
"loc": {
"start": {
"line": 4,
"column": 0
},
"end": {
"line": 4,
"column": 23
}
}
}
]
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "Identifier",
"name": "describe",
"range": [
109,
117
],
"loc": {
"start": {
"line": 5,
"column": 0
},
"end": {
"line": 5,
"column": 8
}
}
},
"arguments": [
{
"type": "Literal",
"value": "Observable.prototype.distinct",
"raw": "'Observable.prototype.distinct'",
"range": [
118,
149
],
"loc": {
"start": {
"line": 5,
"column": 9
},
"end": {
"line": 5,
"column": 40
}
}
},
{
"type": "FunctionExpression",
"id": null,
"params": [],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "Identifier",
"name": "it",
"range": [
169,
171
],
"loc": {
"start": {
"line": 6,
"column": 4
},
"end": {
"line": 6,
"column": 6
}
}
},
"arguments": [
{
"type": "Literal",
"value": "should distinguish between values",
"raw": "'should distinguish between values'",
"range": [
172,
207
],
"loc": {
"start": {
"line": 6,
"column": 7
},
"end": {
"line": 6,
"column": 42
}
}
},
{
"type": "FunctionExpression",
"id": null,
"params": [],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "e1",
"range": [
235,
237
],
"loc": {
"start": {
"line": 7,
"column": 12
},
"end": {
"line": 7,
"column": 14
}
}
},
"init": {
"type": "CallExpression",
"callee": {
"type": "Identifier",
"name": "hot",
"range": [
240,
243
],
"loc": {
"start": {
"line": 7,
"column": 17
},
"end": {
"line": 7,
"column": 20
}
}
},
"arguments": [
{
"type": "Literal",
"value": "--a--a--a--b--b--a--|",
"raw": "'--a--a--a--b--b--a--|'",
"range": [
244,
267
],
"loc": {
"start": {
"line": 7,
"column": 21
},
"end": {
"line": 7,
"column": 44
}
}
}
],
"range": [
240,
268
],
"loc": {
"start": {
"line": 7,
"column": 17
},
"end": {
"line": 7,
"column": 45
}
}
},
"range": [
235,
268
],
"loc": {
"start": {
"line": 7,
"column": 12
},
"end": {
"line": 7,
"column": 45
}
}
}
],
"kind": "var",
"range": [
231,
269
],
"loc": {
"start": {
"line": 7,
"column": 8
},
"end": {
"line": 7,
"column": 46
}
}
},
{
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "e1subs",
"range": [
282,
288
],
"loc": {
"start": {
"line": 8,
"column": 12
},
"end": {
"line": 8,
"column": 18
}
}
},
"init": {
"type": "Literal",
"value": "^ !",
"raw": "'^ !'",
"range": [
291,
314
],
"loc": {
"start": {
"line": 8,
"column": 21
},
"end": {
"line": 8,
"column": 44
}
}
},
"range": [
282,
314
],
"loc": {
"start": {
"line": 8,
"column": 12
},
"end": {
"line": 8,
"column": 44
}
}
}
],
"kind": "var",
"range": [
278,
315
],
"loc": {
"start": {
"line": 8,
"column": 8
},
"end": {
"line": 8,
"column": 45
}
}
},
{
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "expected",
"range": [
328,
336
],
"loc": {
"start": {
"line": 9,
"column": 12
},
"end": {
"line": 9,
"column": 20
}
}
},
"init": {
"type": "Literal",
"value": "--a--------b--------|",
"raw": "'--a--------b--------|'",
"range": [
339,
362
],
"loc": {
"start": {
"line": 9,
"column": 23
},
"end": {
"line": 9,
"column": 46
}
}
},
"range": [
328,
362
],
"loc": {
"start": {
"line": 9,
"column": 12
},
"end": {
"line": 9,
"column": 46
}
}
}
],
"kind": "var",
"range": [
324,
363
],
"loc": {
"start": {
"line": 9,
"column": 8
},
"end": {
"line": 9,
"column": 47
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "CallExpression",
"callee": {
"type": "Identifier",
"name": "expectObservable",
"range": [
372,
388
],
"loc": {
"start": {
"line": 10,
"column": 8
},
"end": {
"line": 10,
"column": 24
}
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "e1",
"range": [
389,
391
],
"loc": {
"start": {
"line": 10,
"column": 25
},
"end": {
"line": 10,
"column": 27
}
}
},
"property": {
"type": "Identifier",
"name": "distinct",
"range": [
392,
400
],
"loc": {
"start": {
"line": 10,
"column": 28
},
"end": {
"line": 10,
"column": 36
}
}
},
"range": [
389,
400
],
"loc": {
"start": {
"line": 10,
"column": 25
},
"end": {
"line": 10,
"column": 36
}
}
},
"arguments": [],
"range": [
389,
402
],
"loc": {
"start": {
"line": 10,
"column": 25
},
"end": {
"line": 10,
"column": 38
}
}
}
],
"range": [
372,
403
],
"loc": {
"start": {
"line": 10,
"column": 8
},
"end": {
"line": 10,
"column": 39
}
}
},
"property": {
"type": "Identifier",
"name": "toBe",
"range": [
404,
408
],
"loc": {
"start": {
"line": 10,
"column": 40
},
"end": {
"line": 10,
"column": 44
}
}
},
"range": [
372,
408
],
"loc": {
"start": {
"line": 10,
"column": 8
},
"end": {
"line": 10,
"column": 44
}
}
},
"arguments": [
{
"type": "Identifier",
"name": "expected",
"range": [
409,
417
],
"loc": {
"start": {
"line": 10,
"column": 45
},
"end": {
"line": 10,
"column": 53
}
}
}
],
"range": [
372,
418
],
"loc": {
"start": {
"line": 10,
"column": 8
},
"end": {
"line": 10,
"column": 54
}
}
},
"range": [
372,
419
],
"loc": {
"start": {
"line": 10,
"column": 8
},
"end": {
"line": 10,
"column": 55
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "CallExpression",
"callee": {
"type": "Identifier",
"name": "expectSubscriptions",
"range": [
428,
447
],
"loc": {
"start": {
"line": 11,
"column": 8
},
"end": {
"line": 11,
"column": 27
}
}
},
"arguments": [
{
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "e1",
"range": [
448,
450
],
"loc": {
"start": {
"line": 11,
"column": 28
},
"end": {
"line": 11,
"column": 30
}
}
},
"property": {
"type": "Identifier",
"name": "subscriptions",
"range": [
451,
464
],
"loc": {
"start": {
"line": 11,
"column": 31
},
"end": {
"line": 11,
"column": 44
}
}
},
"range": [
448,
464
],
"loc": {
"start": {
"line": 11,
"column": 28
},
"end": {
"line": 11,
"column": 44
}
}
}
],
"range": [
428,
465
],
"loc": {
"start": {
"line": 11,
"column": 8
},
"end": {
"line": 11,
"column": 45
}
}
},
"property": {
"type": "Identifier",
"name": "toBe",
"range": [
466,
470
],
"loc": {
"start": {
"line": 11,
"column": 46
},
"end": {
"line": 11,
"column": 50
}
}
},
"range": [
428,
470
],
"loc": {
"start": {
"line": 11,
"column": 8
},
"end": {
"line": 11,
"column": 50
}
}
},
"arguments": [
{
"type": "Identifier",
"name": "e1subs",
"range": [
471,
477
],
"loc": {
"start": {
"line": 11,
"column": 51
},
"end": {
"line": 11,
"column": 57
}
}
}
],
"range": [
428,
478
],
"loc": {
"start": {
"line": 11,
"column": 8
},
"end": {
"line": 11,
"column": 58
}
}
},
"range": [
428,
479
],
"loc": {
"start": {
"line": 11,
"column": 8
},
"end": {
"line": 11,
"column": 59
}
}
}
],
"range": [
221,
485
],
"loc": {
"start": {
"line": 6,
"column": 56
},
"end": {
"line": 12,
"column": 5
}
}
},
"generator": false,
"expression": false,
"range": [
209,
485
],
"loc": {
"start": {
"line": 6,
"column": 44
},
"end": {
"line": 12,
"column": 5
}
}
}
],
"range": [
169,
486
],
"loc": {
"start": {
"line": 6,
"column": 4
},
"end": {
"line": 12,
"column": 6
}
},
"_esdocTestId": 975,
"_esdocTestName": "it975"
},
"range": [
169,
487
],
"loc": {
"start": {
"line": 6,
"column": 4
},
"end": {
"line": 12,
"column": 7
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "Identifier",
"name": "it",
"range": [
492,
494
],
"loc": {
"start": {
"line": 13,
"column": 4
},
"end": {
"line": 13,
"column": 6
}
}
},
"arguments": [
{
"type": "Literal",
"value": "should distinguish between values and does not completes",
"raw": "'should distinguish between values and does not completes'",
"range": [
495,
553
],
"loc": {
"start": {
"line": 13,
"column": 7
},
"end": {
"line": 13,
"column": 65
}
}
},
{
"type": "FunctionExpression",
"id": null,
"params": [],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "e1",
"range": [
581,
583
],
"loc": {
"start": {
"line": 14,
"column": 12
},
"end": {
"line": 14,
"column": 14
}
}
},
"init": {
"type": "CallExpression",
"callee": {
"type": "Identifier",
"name": "hot",
"range": [
586,
589
],
"loc": {
"start": {
"line": 14,
"column": 17
},
"end": {
"line": 14,
"column": 20
}
}
},
"arguments": [
{
"type": "Literal",
"value": "--a--a--a--b--b--a-",
"raw": "'--a--a--a--b--b--a-'",
"range": [
590,
611
],
"loc": {
"start": {
"line": 14,
"column": 21
},
"end": {
"line": 14,
"column": 42
}
}
}
],
"range": [
586,
612
],
"loc": {
"start": {
"line": 14,
"column": 17
},
"end": {
"line": 14,
"column": 43
}
}
},
"range": [
581,
612
],
"loc": {
"start": {
"line": 14,
"column": 12
},
"end": {
"line": 14,
"column": 43
}
}
}
],
"kind": "var",
"range": [
577,
613
],
"loc": {
"start": {
"line": 14,
"column": 8
},
"end": {
"line": 14,
"column": 44
}
}
},
{
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "e1subs",
"range": [
626,
632
],
"loc": {
"start": {
"line": 15,
"column": 12
},
"end": {
"line": 15,
"column": 18
}
}
},
"init": {
"type": "Literal",
"value": "^ ",
"raw": "'^ '",
"range": [
635,
656
],
"loc": {
"start": {
"line": 15,
"column": 21
},
"end": {
"line": 15,
"column": 42
}
}
},
"range": [
626,
656
],
"loc": {
"start": {
"line": 15,
"column": 12
},
"end": {
"line": 15,
"column": 42
}
}
}