UNPKG

@reactivex/rxjs

Version:

Reactive Extensions for modern JavaScript

1,082 lines (1,081 loc) 327 kB
{ "type": "Program", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "describe", "range": [ 24, 32 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 8 } } }, "arguments": [ { "type": "Literal", "value": "Observable.prototype.pairwise", "raw": "'Observable.prototype.pairwise'", "range": [ 33, 64 ], "loc": { "start": { "line": 2, "column": 9 }, "end": { "line": 2, "column": 40 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "asDiagram", "range": [ 84, 93 ], "loc": { "start": { "line": 3, "column": 4 }, "end": { "line": 3, "column": 13 } } }, "arguments": [ { "type": "Literal", "value": "pairwise", "raw": "'pairwise'", "range": [ 94, 104 ], "loc": { "start": { "line": 3, "column": 14 }, "end": { "line": 3, "column": 24 } } } ], "range": [ 84, 105 ], "loc": { "start": { "line": 3, "column": 4 }, "end": { "line": 3, "column": 25 } } }, "arguments": [ { "type": "Literal", "value": "should group consecutive emissions as arrays of two", "raw": "'should group consecutive emissions as arrays of two'", "range": [ 106, 159 ], "loc": { "start": { "line": 3, "column": 26 }, "end": { "line": 3, "column": 79 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "e1", "range": [ 187, 189 ], "loc": { "start": { "line": 4, "column": 12 }, "end": { "line": 4, "column": 14 } } }, "init": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "hot", "range": [ 192, 195 ], "loc": { "start": { "line": 4, "column": 17 }, "end": { "line": 4, "column": 20 } } }, "arguments": [ { "type": "Literal", "value": "--a--b-c----d--e---|", "raw": "'--a--b-c----d--e---|'", "range": [ 196, 218 ], "loc": { "start": { "line": 4, "column": 21 }, "end": { "line": 4, "column": 43 } } } ], "range": [ 192, 219 ], "loc": { "start": { "line": 4, "column": 17 }, "end": { "line": 4, "column": 44 } } }, "range": [ 187, 219 ], "loc": { "start": { "line": 4, "column": 12 }, "end": { "line": 4, "column": 44 } } } ], "kind": "var", "range": [ 183, 220 ], "loc": { "start": { "line": 4, "column": 8 }, "end": { "line": 4, "column": 45 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "expected", "range": [ 233, 241 ], "loc": { "start": { "line": 5, "column": 12 }, "end": { "line": 5, "column": 20 } } }, "init": { "type": "Literal", "value": "-----u-v----w--x---|", "raw": "'-----u-v----w--x---|'", "range": [ 244, 266 ], "loc": { "start": { "line": 5, "column": 23 }, "end": { "line": 5, "column": 45 } } }, "range": [ 233, 266 ], "loc": { "start": { "line": 5, "column": 12 }, "end": { "line": 5, "column": 45 } } } ], "kind": "var", "range": [ 229, 267 ], "loc": { "start": { "line": 5, "column": 8 }, "end": { "line": 5, "column": 46 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "values", "range": [ 280, 286 ], "loc": { "start": { "line": 6, "column": 12 }, "end": { "line": 6, "column": 18 } } }, "init": { "type": "ObjectExpression", "properties": [ { "type": "Property", "key": { "type": "Identifier", "name": "u", "range": [ 303, 304 ], "loc": { "start": { "line": 7, "column": 12 }, "end": { "line": 7, "column": 13 } } }, "value": { "type": "ArrayExpression", "elements": [ { "type": "Literal", "value": "a", "raw": "'a'", "range": [ 307, 310 ], "loc": { "start": { "line": 7, "column": 16 }, "end": { "line": 7, "column": 19 } } }, { "type": "Literal", "value": "b", "raw": "'b'", "range": [ 312, 315 ], "loc": { "start": { "line": 7, "column": 21 }, "end": { "line": 7, "column": 24 } } } ], "range": [ 306, 316 ], "loc": { "start": { "line": 7, "column": 15 }, "end": { "line": 7, "column": 25 } } }, "kind": "init", "method": false, "shorthand": false, "computed": false, "range": [ 303, 316 ], "loc": { "start": { "line": 7, "column": 12 }, "end": { "line": 7, "column": 25 } } }, { "type": "Property", "key": { "type": "Identifier", "name": "v", "range": [ 330, 331 ], "loc": { "start": { "line": 8, "column": 12 }, "end": { "line": 8, "column": 13 } } }, "value": { "type": "ArrayExpression", "elements": [ { "type": "Literal", "value": "b", "raw": "'b'", "range": [ 334, 337 ], "loc": { "start": { "line": 8, "column": 16 }, "end": { "line": 8, "column": 19 } } }, { "type": "Literal", "value": "c", "raw": "'c'", "range": [ 339, 342 ], "loc": { "start": { "line": 8, "column": 21 }, "end": { "line": 8, "column": 24 } } } ], "range": [ 333, 343 ], "loc": { "start": { "line": 8, "column": 15 }, "end": { "line": 8, "column": 25 } } }, "kind": "init", "method": false, "shorthand": false, "computed": false, "range": [ 330, 343 ], "loc": { "start": { "line": 8, "column": 12 }, "end": { "line": 8, "column": 25 } } }, { "type": "Property", "key": { "type": "Identifier", "name": "w", "range": [ 357, 358 ], "loc": { "start": { "line": 9, "column": 12 }, "end": { "line": 9, "column": 13 } } }, "value": { "type": "ArrayExpression", "elements": [ { "type": "Literal", "value": "c", "raw": "'c'", "range": [ 361, 364 ], "loc": { "start": { "line": 9, "column": 16 }, "end": { "line": 9, "column": 19 } } }, { "type": "Literal", "value": "d", "raw": "'d'", "range": [ 366, 369 ], "loc": { "start": { "line": 9, "column": 21 }, "end": { "line": 9, "column": 24 } } } ], "range": [ 360, 370 ], "loc": { "start": { "line": 9, "column": 15 }, "end": { "line": 9, "column": 25 } } }, "kind": "init", "method": false, "shorthand": false, "computed": false, "range": [ 357, 370 ], "loc": { "start": { "line": 9, "column": 12 }, "end": { "line": 9, "column": 25 } } }, { "type": "Property", "key": { "type": "Identifier", "name": "x", "range": [ 384, 385 ], "loc": { "start": { "line": 10, "column": 12 }, "end": { "line": 10, "column": 13 } } }, "value": { "type": "ArrayExpression", "elements": [ { "type": "Literal", "value": "d", "raw": "'d'", "range": [ 388, 391 ], "loc": { "start": { "line": 10, "column": 16 }, "end": { "line": 10, "column": 19 } } }, { "type": "Literal", "value": "e", "raw": "'e'", "range": [ 393, 396 ], "loc": { "start": { "line": 10, "column": 21 }, "end": { "line": 10, "column": 24 } } } ], "range": [ 387, 397 ], "loc": { "start": { "line": 10, "column": 15 }, "end": { "line": 10, "column": 25 } } }, "kind": "init", "method": false, "shorthand": false, "computed": false, "range": [ 384, 397 ], "loc": { "start": { "line": 10, "column": 12 }, "end": { "line": 10, "column": 25 } } } ], "range": [ 289, 407 ], "loc": { "start": { "line": 6, "column": 21 }, "end": { "line": 11, "column": 9 } } }, "range": [ 280, 407 ], "loc": { "start": { "line": 6, "column": 12 }, "end": { "line": 11, "column": 9 } } } ], "kind": "var", "range": [ 276, 408 ], "loc": { "start": { "line": 6, "column": 8 }, "end": { "line": 11, "column": 10 } } }, { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "source", "range": [ 421, 427 ], "loc": { "start": { "line": 12, "column": 12 }, "end": { "line": 12, "column": 18 } } }, "init": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "e1", "range": [ 430, 432 ], "loc": { "start": { "line": 12, "column": 21 }, "end": { "line": 12, "column": 23 } } }, "property": { "type": "Identifier", "name": "pairwise", "range": [ 433, 441 ], "loc": { "start": { "line": 12, "column": 24 }, "end": { "line": 12, "column": 32 } } }, "range": [ 430, 441 ], "loc": { "start": { "line": 12, "column": 21 }, "end": { "line": 12, "column": 32 } } }, "arguments": [], "range": [ 430, 443 ], "loc": { "start": { "line": 12, "column": 21 }, "end": { "line": 12, "column": 34 } } }, "range": [ 421, 443 ], "loc": { "start": { "line": 12, "column": 12 }, "end": { "line": 12, "column": 34 } } } ], "kind": "var", "range": [ 417, 444 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 35 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "expectObservable", "range": [ 453, 469 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 24 } } }, "arguments": [ { "type": "Identifier", "name": "source", "range": [ 470, 476 ], "loc": { "start": { "line": 13, "column": 25 }, "end": { "line": 13, "column": 31 } } } ], "range": [ 453, 477 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 32 } } }, "property": { "type": "Identifier", "name": "toBe", "range": [ 478, 482 ], "loc": { "start": { "line": 13, "column": 33 }, "end": { "line": 13, "column": 37 } } }, "range": [ 453, 482 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 37 } } }, "arguments": [ { "type": "Identifier", "name": "expected", "range": [ 483, 491 ], "loc": { "start": { "line": 13, "column": 38 }, "end": { "line": 13, "column": 46 } } }, { "type": "Identifier", "name": "values", "range": [ 493, 499 ], "loc": { "start": { "line": 13, "column": 48 }, "end": { "line": 13, "column": 54 } } } ], "range": [ 453, 500 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 55 } } }, "range": [ 453, 501 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 56 } } } ], "range": [ 173, 507 ], "loc": { "start": { "line": 3, "column": 93