UNPKG

@reactivex/rxjs

Version:

Reactive Extensions for modern JavaScript

1,429 lines (1,428 loc) 3.01 MB
{ "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": "_this", "range": [ 18, 23 ], "loc": { "start": { "line": 2, "column": 4 }, "end": { "line": 2, "column": 9 } } }, "init": { "type": "ThisExpression", "range": [ 26, 30 ], "loc": { "start": { "line": 2, "column": 12 }, "end": { "line": 2, "column": 16 } } }, "range": [ 18, 30 ], "loc": { "start": { "line": 2, "column": 4 }, "end": { "line": 2, "column": 16 } } } ], "kind": "var", "range": [ 14, 31 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 17 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "chai_1", "range": [ 36, 42 ], "loc": { "start": { "line": 3, "column": 4 }, "end": { "line": 3, "column": 10 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "require", "range": [ 45, 52 ], "loc": { "start": { "line": 3, "column": 13 }, "end": { "line": 3, "column": 20 } } }, "arguments": [ { "type": "Literal", "value": "chai", "raw": "'chai'", "range": [ 53, 59 ], "loc": { "start": { "line": 3, "column": 21 }, "end": { "line": 3, "column": 27 } } } ], "range": [ 45, 60 ], "loc": { "start": { "line": 3, "column": 13 }, "end": { "line": 3, "column": 28 } } }, "range": [ 36, 60 ], "loc": { "start": { "line": 3, "column": 4 }, "end": { "line": 3, "column": 28 } } } ], "kind": "var", "range": [ 32, 61 ], "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 3, "column": 29 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "Rx", "range": [ 66, 68 ], "loc": { "start": { "line": 4, "column": 4 }, "end": { "line": 4, "column": 6 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "require", "range": [ 71, 78 ], "loc": { "start": { "line": 4, "column": 9 }, "end": { "line": 4, "column": 16 } } }, "arguments": [ { "type": "Literal", "value": "../../dist/cjs/Rx", "raw": "'../../dist/cjs/Rx'", "range": [ 79, 98 ], "loc": { "start": { "line": 4, "column": 17 }, "end": { "line": 4, "column": 36 } } } ], "range": [ 71, 99 ], "loc": { "start": { "line": 4, "column": 9 }, "end": { "line": 4, "column": 37 } } }, "range": [ 66, 99 ], "loc": { "start": { "line": 4, "column": 4 }, "end": { "line": 4, "column": 37 } } } ], "kind": "var", "range": [ 62, 100 ], "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 4, "column": 38 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "Observable", "range": [ 105, 115 ], "loc": { "start": { "line": 5, "column": 4 }, "end": { "line": 5, "column": 14 } } }, "init": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "Rx", "range": [ 118, 120 ], "loc": { "start": { "line": 5, "column": 17 }, "end": { "line": 5, "column": 19 } } }, "property": { "type": "Identifier", "name": "Observable", "range": [ 121, 131 ], "loc": { "start": { "line": 5, "column": 20 }, "end": { "line": 5, "column": 30 } } }, "range": [ 118, 131 ], "loc": { "start": { "line": 5, "column": 17 }, "end": { "line": 5, "column": 30 } } }, "range": [ 105, 131 ], "loc": { "start": { "line": 5, "column": 4 }, "end": { "line": 5, "column": 30 } } } ], "kind": "var", "range": [ 101, 132 ], "loc": { "start": { "line": 5, "column": 0 }, "end": { "line": 5, "column": 31 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "queueScheduler", "range": [ 137, 151 ], "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 6, "column": 18 } } }, "init": { "type": "MemberExpression", "computed": false, "object": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "Rx", "range": [ 154, 156 ], "loc": { "start": { "line": 6, "column": 21 }, "end": { "line": 6, "column": 23 } } }, "property": { "type": "Identifier", "name": "Scheduler", "range": [ 157, 166 ], "loc": { "start": { "line": 6, "column": 24 }, "end": { "line": 6, "column": 33 } } }, "range": [ 154, 166 ], "loc": { "start": { "line": 6, "column": 21 }, "end": { "line": 6, "column": 33 } } }, "property": { "type": "Identifier", "name": "queue", "range": [ 167, 172 ], "loc": { "start": { "line": 6, "column": 34 }, "end": { "line": 6, "column": 39 } } }, "range": [ 154, 172 ], "loc": { "start": { "line": 6, "column": 21 }, "end": { "line": 6, "column": 39 } } }, "range": [ 137, 172 ], "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 6, "column": 39 } } } ], "kind": "var", "range": [ 133, 173 ], "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 6, "column": 40 } }, "trailingComments": [ { "type": "Block", "value": "* @test {zip} ", "range": [ 174, 192 ], "loc": { "start": { "line": 7, "column": 0 }, "end": { "line": 7, "column": 18 } } } ] }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "describe", "range": [ 193, 201 ], "loc": { "start": { "line": 8, "column": 0 }, "end": { "line": 8, "column": 8 } } }, "arguments": [ { "type": "Literal", "value": "Observable.zip", "raw": "'Observable.zip'", "range": [ 202, 218 ], "loc": { "start": { "line": 8, "column": 9 }, "end": { "line": 8, "column": 25 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "it", "range": [ 238, 240 ], "loc": { "start": { "line": 9, "column": 4 }, "end": { "line": 9, "column": 6 } } }, "arguments": [ { "type": "Literal", "value": "should combine a source with a second", "raw": "'should combine a source with a second'", "range": [ 241, 280 ], "loc": { "start": { "line": 9, "column": 7 }, "end": { "line": 9, "column": 46 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "a", "range": [ 308, 309 ], "loc": { "start": { "line": 10, "column": 12 }, "end": { "line": 10, "column": 13 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "hot", "range": [ 312, 315 ], "loc": { "start": { "line": 10, "column": 16 }, "end": { "line": 10, "column": 19 } } }, "arguments": [ { "type": "Literal", "value": "---1---2---3---", "raw": "'---1---2---3---'", "range": [ 316, 333 ], "loc": { "start": { "line": 10, "column": 20 }, "end": { "line": 10, "column": 37 } } } ], "range": [ 312, 334 ], "loc": { "start": { "line": 10, "column": 16 }, "end": { "line": 10, "column": 38 } } }, "range": [ 308, 334 ], "loc": { "start": { "line": 10, "column": 12 }, "end": { "line": 10, "column": 38 } } } ], "kind": "var", "range": [ 304, 335 ], "loc": { "start": { "line": 10, "column": 8 }, "end": { "line": 10, "column": 39 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "asubs", "range": [ 348, 353 ], "loc": { "start": { "line": 11, "column": 12 }, "end": { "line": 11, "column": 17 } } }, "init": { "type": "Literal", "value": "^", "raw": "'^'", "range": [ 356, 359 ], "loc": { "start": { "line": 11, "column": 20 }, "end": { "line": 11, "column": 23 } } }, "range": [ 348, 359 ], "loc": { "start": { "line": 11, "column": 12 }, "end": { "line": 11, "column": 23 } } } ], "kind": "var", "range": [ 344, 360 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 24 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "b", "range": [ 373, 374 ], "loc": { "start": { "line": 12, "column": 12 }, "end": { "line": 12, "column": 13 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "hot", "range": [ 377, 380 ], "loc": { "start": { "line": 12, "column": 16 }, "end": { "line": 12, "column": 19 } } }, "arguments": [ { "type": "Literal", "value": "--4--5--6--7--8--", "raw": "'--4--5--6--7--8--'", "range": [ 381, 400 ], "loc": { "start": { "line": 12, "column": 20 }, "end": { "line": 12, "column": 39 } } } ], "range": [ 377, 401 ], "loc": { "start": { "line": 12, "column": 16 }, "end": { "line": 12, "column": 40 } } }, "range": [ 373, 401 ], "loc": { "start": { "line": 12, "column": 12 }, "end": { "line": 12, "column": 40 } } } ], "kind": "var", "range": [ 369, 402 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 41 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "bsubs", "range": [ 415, 420 ], "loc": { "start": { "line": 13, "column": 12 }, "end": { "line": 13, "column": 17 } } }, "init": { "type": "Literal", "value": "^", "raw": "'^'", "range": [ 423, 426 ], "loc": { "start": { "line": 13, "column": 20 }, "end": { "line": 13, "column": 23 } } }, "range": [ 415, 426 ], "loc": { "start": { "line": 13, "column": 12 }, "end": { "line": 13, "column": 23 } } } ], "kind": "var", "range": [ 411, 427 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 24 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "expected", "range": [ 440, 448 ], "loc": { "start": { "line": 14, "column": 12 }, "end": { "line": 14, "column": 20 } } }, "init": { "type": "Literal", "value": "---x---y---z", "raw": "'---x---y---z'", "range": [ 451, 465 ], "loc": { "start": { "line": 14, "column": 23 }, "end": { "line": 14, "column": 37 } } }, "range": [ 440, 465 ], "loc": { "start": { "line": 14, "column": 12 }, "end": { "line": 14, "column": 37 } } } ], "kind": "var", "range": [ 436, 466 ], "loc": { "start": { "line": 14, "column": 8 }, "end": { "line": 14, "column": 38 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "expectObservable", "range": [ 475, 491 ], "loc": { "start": { "line": 15, "column": 8 }, "end": { "line": 15, "column": 24 } } }, "arguments": [ { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "Observable", "range": [ 492, 502 ], "loc": { "start": { "line": 15, "column": 25 }, "end": { "line": 15, "column": 35 } } }, "property": { "type": "Identifier", "name": "zip", "range": [ 503, 506 ], "loc": { "start": { "line": 15, "column": 36 }, "end": { "line": 15, "column": 39 } } }, "range": [ 492, 506 ], "loc": { "start": { "line": 15, "column": 25 }, "end": { "line": 15, "column": 39 } } }, "arguments": [ { "type": "Identifier", "name": "a", "range": [ 507, 508 ], "loc": { "start": { "line": 15, "column": 40 }, "end": { "line": 15, "column": 41 } } }, { "type": "Identifier", "name": "b", "range": [ 510, 511 ], "loc": { "start": { "line": 15, "column": 43 }, "end": { "line": 15, "column": 44 } } } ], "range": [ 492, 512 ], "loc": { "start": { "line": 15, "column": 25 }, "end": { "line": 15, "column": 45 } } } ], "range": [ 475, 513 ], "loc": { "start": { "line": 15, "column": 8 }, "end": { "line": 15, "column": 46 } } }, "property": { "type": "Identifier", "name": "toBe", "range": [ 527, 531 ], "loc": { "start": { "line": 16, "column": 13 }, "end": { "line": 16, "column": 17 } } }, "range": [ 475, 531 ], "loc": { "start": { "line": 15, "column": 8 }, "end": { "line": 16, "column": 17 } } }, "arguments": [ { "type": "Identifier", "name": "expected", "range": [ 532, 540 ], "loc": { "start": { "line": 16, "column": 18 }, "end": { "line": 16, "column": 26 } } }, { "type": "ObjectExpression", "properties": [ { "type": "Property", "key": { "type": "Identifier", "name": "x", "range": [ 544, 545 ], "loc": { "start": { "line": 16, "column": 30 }, "end": { "line": 16, "column": 31 } } }, "value": { "type": "ArrayExpression", "elements": [ { "type": "Literal", "value": "1", "raw": "'1'", "range": [ 548, 551 ], "loc": { "start": { "line": 16, "column": 34 }, "end": { "line": 16, "column": 37 } } }, { "type": "Literal", "value": "4", "raw": "'4'", "range": [ 553, 556 ], "loc": { "start": { "line": 16, "column": 39 }, "end": { "line": 16, "column": 42 } } } ], "range": [ 547, 557 ], "loc": { "start": { "line": 16, "column": 33 },