UNPKG

@reactivex/rxjs

Version:

Reactive Extensions for modern JavaScript

1,310 lines (1,309 loc) 1.4 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": "chai_1", "range": [ 18, 24 ], "loc": { "start": { "line": 2, "column": 4 }, "end": { "line": 2, "column": 10 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "require", "range": [ 27, 34 ], "loc": { "start": { "line": 2, "column": 13 }, "end": { "line": 2, "column": 20 } } }, "arguments": [ { "type": "Literal", "value": "chai", "raw": "'chai'", "range": [ 35, 41 ], "loc": { "start": { "line": 2, "column": 21 }, "end": { "line": 2, "column": 27 } } } ], "range": [ 27, 42 ], "loc": { "start": { "line": 2, "column": 13 }, "end": { "line": 2, "column": 28 } } }, "range": [ 18, 42 ], "loc": { "start": { "line": 2, "column": 4 }, "end": { "line": 2, "column": 28 } } } ], "kind": "var", "range": [ 14, 43 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 29 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "Rx", "range": [ 48, 50 ], "loc": { "start": { "line": 3, "column": 4 }, "end": { "line": 3, "column": 6 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "require", "range": [ 53, 60 ], "loc": { "start": { "line": 3, "column": 9 }, "end": { "line": 3, "column": 16 } } }, "arguments": [ { "type": "Literal", "value": "../dist/cjs/Rx", "raw": "'../dist/cjs/Rx'", "range": [ 61, 77 ], "loc": { "start": { "line": 3, "column": 17 }, "end": { "line": 3, "column": 33 } } } ], "range": [ 53, 78 ], "loc": { "start": { "line": 3, "column": 9 }, "end": { "line": 3, "column": 34 } } }, "range": [ 48, 78 ], "loc": { "start": { "line": 3, "column": 4 }, "end": { "line": 3, "column": 34 } } } ], "kind": "var", "range": [ 44, 79 ], "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 3, "column": 35 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "Notification", "range": [ 84, 96 ], "loc": { "start": { "line": 4, "column": 4 }, "end": { "line": 4, "column": 16 } } }, "init": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "Rx", "range": [ 99, 101 ], "loc": { "start": { "line": 4, "column": 19 }, "end": { "line": 4, "column": 21 } } }, "property": { "type": "Identifier", "name": "Notification", "range": [ 102, 114 ], "loc": { "start": { "line": 4, "column": 22 }, "end": { "line": 4, "column": 34 } } }, "range": [ 99, 114 ], "loc": { "start": { "line": 4, "column": 19 }, "end": { "line": 4, "column": 34 } } }, "range": [ 84, 114 ], "loc": { "start": { "line": 4, "column": 4 }, "end": { "line": 4, "column": 34 } } } ], "kind": "var", "range": [ 80, 115 ], "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 4, "column": 35 } }, "trailingComments": [ { "type": "Block", "value": "* @test {Notification} ", "range": [ 116, 143 ], "loc": { "start": { "line": 5, "column": 0 }, "end": { "line": 5, "column": 27 } } } ] }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "describe", "range": [ 144, 152 ], "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 6, "column": 8 } } }, "arguments": [ { "type": "Literal", "value": "Notification", "raw": "'Notification'", "range": [ 153, 167 ], "loc": { "start": { "line": 6, "column": 9 }, "end": { "line": 6, "column": 23 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "it", "range": [ 187, 189 ], "loc": { "start": { "line": 7, "column": 4 }, "end": { "line": 7, "column": 6 } } }, "arguments": [ { "type": "Literal", "value": "should exist", "raw": "'should exist'", "range": [ 190, 204 ], "loc": { "start": { "line": 7, "column": 7 }, "end": { "line": 7, "column": 21 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "MemberExpression", "computed": false, "object": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "chai_1", "range": [ 228, 234 ], "loc": { "start": { "line": 8, "column": 8 }, "end": { "line": 8, "column": 14 } } }, "property": { "type": "Identifier", "name": "expect", "range": [ 235, 241 ], "loc": { "start": { "line": 8, "column": 15 }, "end": { "line": 8, "column": 21 } } }, "range": [ 228, 241 ], "loc": { "start": { "line": 8, "column": 8 }, "end": { "line": 8, "column": 21 } } }, "arguments": [ { "type": "Identifier", "name": "Notification", "range": [ 242, 254 ], "loc": { "start": { "line": 8, "column": 22 }, "end": { "line": 8, "column": 34 } } } ], "range": [ 228, 255 ], "loc": { "start": { "line": 8, "column": 8 }, "end": { "line": 8, "column": 35 } } }, "property": { "type": "Identifier", "name": "exist", "range": [ 256, 261 ], "loc": { "start": { "line": 8, "column": 36 }, "end": { "line": 8, "column": 41 } } }, "range": [ 228, 261 ], "loc": { "start": { "line": 8, "column": 8 }, "end": { "line": 8, "column": 41 } } }, "range": [ 228, 262 ], "loc": { "start": { "line": 8, "column": 8 }, "end": { "line": 8, "column": 42 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "MemberExpression", "computed": false, "object": { "type": "MemberExpression", "computed": false, "object": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "chai_1", "range": [ 271, 277 ], "loc": { "start": { "line": 9, "column": 8 }, "end": { "line": 9, "column": 14 } } }, "property": { "type": "Identifier", "name": "expect", "range": [ 278, 284 ], "loc": { "start": { "line": 9, "column": 15 }, "end": { "line": 9, "column": 21 } } }, "range": [ 271, 284 ], "loc": { "start": { "line": 9, "column": 8 }, "end": { "line": 9, "column": 21 } } }, "arguments": [ { "type": "Identifier", "name": "Notification", "range": [ 285, 297 ], "loc": { "start": { "line": 9, "column": 22 }, "end": { "line": 9, "column": 34 } } } ], "range": [ 271, 298 ], "loc": { "start": { "line": 9, "column": 8 }, "end": { "line": 9, "column": 35 } } }, "property": { "type": "Identifier", "name": "to", "range": [ 299, 301 ], "loc": { "start": { "line": 9, "column": 36 }, "end": { "line": 9, "column": 38 } } }, "range": [ 271, 301 ], "loc": { "start": { "line": 9, "column": 8 }, "end": { "line": 9, "column": 38 } } }, "property": { "type": "Identifier", "name": "be", "range": [ 302, 304 ], "loc": { "start": { "line": 9, "column": 39 }, "end": { "line": 9, "column": 41 } } }, "range": [ 271, 304 ], "loc": { "start": { "line": 9, "column": 8 }, "end": { "line": 9, "column": 41 } } }, "property": { "type": "Identifier", "name": "a", "range": [ 305, 306 ], "loc": { "start": { "line": 9, "column": 42 }, "end": { "line": 9, "column": 43 } } }, "range": [ 271, 306 ], "loc": { "start": { "line": 9, "column": 8 }, "end": { "line": 9, "column": 43 } } }, "arguments": [ { "type": "Literal", "value": "function", "raw": "'function'", "range": [ 307, 317 ], "loc": { "start": { "line": 9, "column": 44 }, "end": { "line": 9, "column": 54 } } } ], "range": [ 271, 318 ], "loc": { "start": { "line": 9, "column": 8 }, "end": { "line": 9, "column": 55 } } }, "range": [ 271, 319 ], "loc": { "start": { "line": 9, "column": 8 }, "end": { "line": 9, "column": 56 } } } ], "range": [ 218, 325 ], "loc": { "start": { "line": 7, "column": 35 }, "end": { "line": 10, "column": 5 } } }, "generator": false, "expression": false, "range": [ 206, 325 ], "loc": { "start": { "line": 7, "column": 23 }, "end": { "line": 10, "column": 5 } } } ], "range": [ 187, 326 ], "loc": { "start": { "line": 7, "column": 4 }, "end": { "line": 10, "column": 6 } }, "_esdocTestId": 1, "_esdocTestName": "it1" }, "range": [ 187, 327 ], "loc": { "start": { "line": 7, "column": 4 }, "end": { "line": 10, "column": 7 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "it", "range": [ 332, 334 ], "loc": { "start": { "line": 11, "column": 4 }, "end": { "line": 11, "column": 6 } } }, "arguments": [ { "type": "Literal", "value": "should not allow convert to observable if given kind is unknown", "raw": "'should not allow convert to observable if given kind is unknown'", "range": [ 335, 400 ], "loc": { "start": { "line": 11, "column": 7 }, "end": { "line": 11, "column": 72 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "n", "range": [ 428, 429 ], "loc": { "start": { "line": 12, "column": 12 }, "end": { "line": 12, "column": 13 } } }, "init": { "type": "NewExpression", "callee": { "type": "Identifier", "name": "Notification", "range": [ 436, 448 ], "loc": { "start": { "line": 12, "column": 20 }, "end": { "line": 12, "column": 32 } } }, "arguments": [ { "type": "Literal", "value": "x", "raw": "'x'", "range": [ 449, 452 ], "loc": { "start": { "line": 12, "column": 33 }, "end": { "line": 12, "column": 36 } } } ], "range": [ 432, 453 ], "loc": { "start": { "line": 12, "column": 16 }, "end": { "line": 12, "column": 37 } } }, "range": [ 428, 453 ], "loc": { "start": { "line": 12, "column": 12 }, "end": { "line": 12, "column": 37 } } } ], "kind": "var", "range": [ 424, 454 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 38 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "MemberExpression", "computed": false, "object": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "chai_1", "range": [ 463, 469 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 14 } } }, "property": { "type": "Identifier", "name": "expect", "range": [ 470, 476 ], "loc": { "start": { "line": 13, "column": 15 }, "end": { "line": 13, "column": 21 } } }, "range": [ 463, 476 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 21 } } }, "arguments": [ { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "ReturnStatement", "argument": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "n", "range": [ 498, 499 ], "loc": { "start": { "line": 13, "column": 43 }, "end": { "line": 13, "column": 44 } } }, "property": { "type": "Identifier", "name": "toObservable", "range": [ 500, 512 ], "loc": { "start": { "line": 13, "column": 45 }, "end": { "line": 13, "column": 57 } } }, "range": [ 498, 512 ], "loc": { "start": { "line": 13, "column": 43 }, "end": { "line": 13, "column": 57 } } }, "arguments": [], "range": [ 498, 514 ], "loc": { "start": { "line": 13, "column": 43 }, "end": { "line": 13, "column": 59 } } }, "range": [ 491, 515 ], "loc": { "start": { "line": 13, "column": 36 }, "end": { "line": 13, "column": 60 } } } ], "range": [ 489, 517 ], "loc": { "start": { "line": 13, "column": 34 }, "end": { "line": 13, "column": 62 } } }, "generator": false, "expression": false, "range": [ 477, 517 ], "loc": { "start": { "line": 13, "column": 22 }, "end": { "line": 13, "column": 62 } } } ],