UNPKG

@reactivex/rxjs

Version:

Reactive Extensions for modern JavaScript

1,223 lines 581 kB
{ "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 {timestamp} ", "range": [ 85, 109 ], "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 4, "column": 24 } } } ] }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "describe", "range": [ 110, 118 ], "loc": { "start": { "line": 5, "column": 0 }, "end": { "line": 5, "column": 8 } } }, "arguments": [ { "type": "Literal", "value": "Observable.prototype.timestamp", "raw": "'Observable.prototype.timestamp'", "range": [ 119, 151 ], "loc": { "start": { "line": 5, "column": 9 }, "end": { "line": 5, "column": 41 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "asDiagram", "range": [ 171, 180 ], "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 6, "column": 13 } } }, "arguments": [ { "type": "Literal", "value": "timestamp", "raw": "'timestamp'", "range": [ 181, 192 ], "loc": { "start": { "line": 6, "column": 14 }, "end": { "line": 6, "column": 25 } } } ], "range": [ 171, 193 ], "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 6, "column": 26 } } }, "arguments": [ { "type": "Literal", "value": "should record the time stamp per each source elements", "raw": "'should record the time stamp per each source elements'", "range": [ 194, 249 ], "loc": { "start": { "line": 6, "column": 27 }, "end": { "line": 6, "column": 82 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "e1", "range": [ 277, 279 ], "loc": { "start": { "line": 7, "column": 12 }, "end": { "line": 7, "column": 14 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "hot", "range": [ 282, 285 ], "loc": { "start": { "line": 7, "column": 17 }, "end": { "line": 7, "column": 20 } } }, "arguments": [ { "type": "Literal", "value": "-b-c-----d--e--|", "raw": "'-b-c-----d--e--|'", "range": [ 286, 304 ], "loc": { "start": { "line": 7, "column": 21 }, "end": { "line": 7, "column": 39 } } } ], "range": [ 282, 305 ], "loc": { "start": { "line": 7, "column": 17 }, "end": { "line": 7, "column": 40 } } }, "range": [ 277, 305 ], "loc": { "start": { "line": 7, "column": 12 }, "end": { "line": 7, "column": 40 } } } ], "kind": "var", "range": [ 273, 306 ], "loc": { "start": { "line": 7, "column": 8 }, "end": { "line": 7, "column": 41 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "e1subs", "range": [ 319, 325 ], "loc": { "start": { "line": 8, "column": 12 }, "end": { "line": 8, "column": 18 } } }, "init": { "type": "Literal", "value": "^ !", "raw": "'^ !'", "range": [ 328, 346 ], "loc": { "start": { "line": 8, "column": 21 }, "end": { "line": 8, "column": 39 } } }, "range": [ 319, 346 ], "loc": { "start": { "line": 8, "column": 12 }, "end": { "line": 8, "column": 39 } } } ], "kind": "var", "range": [ 315, 347 ], "loc": { "start": { "line": 8, "column": 8 }, "end": { "line": 8, "column": 40 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "expected", "range": [ 360, 368 ], "loc": { "start": { "line": 9, "column": 12 }, "end": { "line": 9, "column": 20 } } }, "init": { "type": "Literal", "value": "-w-x-----y--z--|", "raw": "'-w-x-----y--z--|'", "range": [ 371, 389 ], "loc": { "start": { "line": 9, "column": 23 }, "end": { "line": 9, "column": 41 } } }, "range": [ 360, 389 ], "loc": { "start": { "line": 9, "column": 12 }, "end": { "line": 9, "column": 41 } } } ], "kind": "var", "range": [ 356, 390 ], "loc": { "start": { "line": 9, "column": 8 }, "end": { "line": 9, "column": 42 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "expectedValue", "range": [ 403, 416 ], "loc": { "start": { "line": 10, "column": 12 }, "end": { "line": 10, "column": 25 } } }, "init": { "type": "ObjectExpression", "properties": [ { "type": "Property", "key": { "type": "Identifier", "name": "w", "range": [ 421, 422 ], "loc": { "start": { "line": 10, "column": 30 }, "end": { "line": 10, "column": 31 } } }, "value": { "type": "Literal", "value": 10, "raw": "10", "range": [ 424, 426 ], "loc": { "start": { "line": 10, "column": 33 }, "end": { "line": 10, "column": 35 } } }, "kind": "init", "method": false, "shorthand": false, "computed": false, "range": [ 421, 426 ], "loc": { "start": { "line": 10, "column": 30 }, "end": { "line": 10, "column": 35 } } }, { "type": "Property", "key": { "type": "Identifier", "name": "x", "range": [ 428, 429 ], "loc": { "start": { "line": 10, "column": 37 }, "end": { "line": 10, "column": 38 } } }, "value": { "type": "Literal", "value": 30, "raw": "30", "range": [ 431, 433 ], "loc": { "start": { "line": 10, "column": 40 }, "end": { "line": 10, "column": 42 } } }, "kind": "init", "method": false, "shorthand": false, "computed": false, "range": [ 428, 433 ], "loc": { "start": { "line": 10, "column": 37 }, "end": { "line": 10, "column": 42 } } }, { "type": "Property", "key": { "type": "Identifier", "name": "y", "range": [ 435, 436 ], "loc": { "start": { "line": 10, "column": 44 }, "end": { "line": 10, "column": 45 } } }, "value": { "type": "Literal", "value": 90, "raw": "90", "range": [ 438, 440 ], "loc": { "start": { "line": 10, "column": 47 }, "end": { "line": 10, "column": 49 } } }, "kind": "init", "method": false, "shorthand": false, "computed": false, "range": [ 435, 440 ], "loc": { "start": { "line": 10, "column": 44 }, "end": { "line": 10, "column": 49 } } }, { "type": "Property", "key": { "type": "Identifier", "name": "z", "range": [ 442, 443 ], "loc": { "start": { "line": 10, "column": 51 }, "end": { "line": 10, "column": 52 } } }, "value": { "type": "Literal", "value": 120, "raw": "120", "range": [ 445, 448 ], "loc": { "start": { "line": 10, "column": 54 }, "end": { "line": 10, "column": 57 } } }, "kind": "init", "method": false, "shorthand": false, "computed": false, "range": [ 442, 448 ], "loc": { "start": { "line": 10, "column": 51 }, "end": { "line": 10, "column": 57 } } } ], "range": [ 419, 450 ], "loc": { "start": { "line": 10, "column": 28 }, "end": { "line": 10, "column": 59 } } }, "range": [ 403, 450 ], "loc": { "start": { "line": 10, "column": 12 }, "end": { "line": 10, "column": 59 } } } ], "kind": "var", "range": [ 399, 451 ], "loc": { "start": { "line": 10, "column": 8 }, "end": { "line": 10, "column": 60 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "result", "range": [ 464, 470 ], "loc": { "start": { "line": 11, "column": 12 }, "end": { "line": 11, "column": 18 } } }, "init": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "e1", "range": [ 473, 475 ], "loc": { "start": { "line": 11, "column": 21 }, "end": { "line": 11, "column": 23 } } }, "property": { "type": "Identifier", "name": "timestamp", "range": [ 476, 485 ], "loc": { "start": { "line": 11, "column": 24 }, "end": { "line": 11, "column": 33 } } }, "range": [ 473, 485 ], "loc": { "start": { "line": 11, "column": 21 }, "end": { "line": 11, "column": 33 } } }, "arguments": [ { "type": "Identifier", "name": "rxTestScheduler", "range": [ 486, 501 ], "loc": { "start": { "line": 11, "column": 34 }, "end": { "line": 11, "column": 49 } } } ], "range": [ 473, 502 ], "loc": { "start": { "line": 11, "column": 21 }, "end": { "line": 11, "column": 50 } } }, "property": { "type": "Identifier", "name": "map", "range": [ 516, 519 ], "loc": { "start": { "line": 12, "column": 13 }, "end": { "line": 12, "column": 16 } } }, "range": [ 473, 519 ], "loc": { "start": { "line": 11, "column": 21 }, "end": { "line": 12, "column": 16 } } }, "arguments": [ { "type": "FunctionExpression", "id": null, "params": [ { "type": "Identifier", "name": "x", "range": [ 530, 531 ], "loc": { "start": { "line": 12, "column": 27 }, "end": { "line": 12, "column": 28 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "ReturnStatement", "argument": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "x", "range": [ 542, 543 ], "loc": { "start": { "line": 12, "column": 39 }, "end": { "line": 12, "column": 40 } } }, "property": { "type": "Identifier", "name": "timestamp", "range": [ 544, 553 ], "loc": { "start": { "line": 12, "column": 41 }, "end": { "line": 12, "column": 50 } } }, "range": [ 542, 553 ], "loc": { "start": { "line": 12, "column": 39 }, "end": { "line": 12, "column": 50 } } }, "range": [ 535, 554 ], "loc": { "start": { "line": 12, "c