UNPKG

dirtybomb

Version:
1,298 lines (1,297 loc) 66.7 kB
{ "type": "Program", "body": [ { "type": "ExpressionStatement", "expression": { "type": "Literal", "value": "use strict", "raw": "\"use strict\"", "range": [ 43, 55 ], "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 6, "column": 12 } } }, "range": [ 43, 56 ], "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 6, "column": 13 } }, "leadingComments": [ { "type": "Block", "value": "*\n * Created by austin on 6/15/16.\n ", "range": [ 0, 40 ], "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 3, "column": 3 } } } ] }, { "type": "ImportDeclaration", "specifiers": [ { "type": "ImportDefaultSpecifier", "local": { "type": "Identifier", "name": "chai", "range": [ 65, 69 ], "loc": { "start": { "line": 8, "column": 7 }, "end": { "line": 8, "column": 11 } } }, "range": [ 65, 69 ], "loc": { "start": { "line": 8, "column": 7 }, "end": { "line": 8, "column": 11 } } } ], "source": { "type": "Literal", "value": "chai", "raw": "'chai'", "range": [ 75, 81 ], "loc": { "start": { "line": 8, "column": 17 }, "end": { "line": 8, "column": 23 } } }, "range": [ 58, 82 ], "loc": { "start": { "line": 8, "column": 0 }, "end": { "line": 8, "column": 24 } } }, { "type": "ImportDeclaration", "specifiers": [ { "type": "ImportDefaultSpecifier", "local": { "type": "Identifier", "name": "Vector", "range": [ 91, 97 ], "loc": { "start": { "line": 10, "column": 7 }, "end": { "line": 10, "column": 13 } } }, "range": [ 91, 97 ], "loc": { "start": { "line": 10, "column": 7 }, "end": { "line": 10, "column": 13 } } } ], "source": { "type": "Literal", "value": "../src/Dispersion/Vector", "raw": "'../src/Dispersion/Vector'", "range": [ 103, 129 ], "loc": { "start": { "line": 10, "column": 19 }, "end": { "line": 10, "column": 45 } } }, "range": [ 84, 130 ], "loc": { "start": { "line": 10, "column": 0 }, "end": { "line": 10, "column": 46 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "chai", "range": [ 132, 136 ], "loc": { "start": { "line": 12, "column": 0 }, "end": { "line": 12, "column": 4 } } }, "property": { "type": "Identifier", "name": "should", "range": [ 137, 143 ], "loc": { "start": { "line": 12, "column": 5 }, "end": { "line": 12, "column": 11 } } }, "range": [ 132, 143 ], "loc": { "start": { "line": 12, "column": 0 }, "end": { "line": 12, "column": 11 } } }, "arguments": [], "range": [ 132, 145 ], "loc": { "start": { "line": 12, "column": 0 }, "end": { "line": 12, "column": 13 } } }, "range": [ 132, 146 ], "loc": { "start": { "line": 12, "column": 0 }, "end": { "line": 12, "column": 14 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "describe", "range": [ 148, 156 ], "loc": { "start": { "line": 14, "column": 0 }, "end": { "line": 14, "column": 8 } } }, "arguments": [ { "type": "Literal", "value": "Vector", "raw": "'Vector'", "range": [ 157, 165 ], "loc": { "start": { "line": 14, "column": 9 }, "end": { "line": 14, "column": 17 } } }, { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "it", "range": [ 185, 187 ], "loc": { "start": { "line": 16, "column": 4 }, "end": { "line": 16, "column": 6 } } }, "arguments": [ { "type": "Literal", "value": "should do basic calculations", "raw": "'should do basic calculations'", "range": [ 188, 218 ], "loc": { "start": { "line": 16, "column": 7 }, "end": { "line": 16, "column": 37 } } }, { "type": "ArrowFunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "x1", "range": [ 240, 242 ], "loc": { "start": { "line": 17, "column": 12 }, "end": { "line": 17, "column": 14 } } }, "init": { "type": "NewExpression", "callee": { "type": "Identifier", "name": "Vector", "range": [ 249, 255 ], "loc": { "start": { "line": 17, "column": 21 }, "end": { "line": 17, "column": 27 } } }, "arguments": [ { "type": "Literal", "value": 1, "raw": "1", "range": [ 256, 257 ], "loc": { "start": { "line": 17, "column": 28 }, "end": { "line": 17, "column": 29 } } }, { "type": "Literal", "value": 0, "raw": "0", "range": [ 259, 260 ], "loc": { "start": { "line": 17, "column": 31 }, "end": { "line": 17, "column": 32 } } }, { "type": "Literal", "value": 0, "raw": "0", "range": [ 262, 263 ], "loc": { "start": { "line": 17, "column": 34 }, "end": { "line": 17, "column": 35 } } } ], "range": [ 245, 264 ], "loc": { "start": { "line": 17, "column": 17 }, "end": { "line": 17, "column": 36 } } }, "range": [ 240, 264 ], "loc": { "start": { "line": 17, "column": 12 }, "end": { "line": 17, "column": 36 } } } ], "kind": "let", "range": [ 236, 265 ], "loc": { "start": { "line": 17, "column": 8 }, "end": { "line": 17, "column": 37 } } }, { "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": "x1", "range": [ 274, 276 ], "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 10 } } }, "property": { "type": "Identifier", "name": "dot", "range": [ 277, 280 ], "loc": { "start": { "line": 18, "column": 11 }, "end": { "line": 18, "column": 14 } } }, "range": [ 274, 280 ], "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 14 } } }, "arguments": [ { "type": "Identifier", "name": "x1", "range": [ 281, 283 ], "loc": { "start": { "line": 18, "column": 15 }, "end": { "line": 18, "column": 17 } } } ], "range": [ 274, 284 ], "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 18 } } }, "property": { "type": "Identifier", "name": "should", "range": [ 285, 291 ], "loc": { "start": { "line": 18, "column": 19 }, "end": { "line": 18, "column": 25 } } }, "range": [ 274, 291 ], "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 25 } } }, "property": { "type": "Identifier", "name": "be", "range": [ 292, 294 ], "loc": { "start": { "line": 18, "column": 26 }, "end": { "line": 18, "column": 28 } } }, "range": [ 274, 294 ], "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 28 } } }, "property": { "type": "Identifier", "name": "closeTo", "range": [ 295, 302 ], "loc": { "start": { "line": 18, "column": 29 }, "end": { "line": 18, "column": 36 } } }, "range": [ 274, 302 ], "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 36 } } }, "arguments": [ { "type": "Literal", "value": 1, "raw": "1", "range": [ 303, 304 ], "loc": { "start": { "line": 18, "column": 37 }, "end": { "line": 18, "column": 38 } } }, { "type": "Literal", "value": 0.01, "raw": "0.01", "range": [ 306, 310 ], "loc": { "start": { "line": 18, "column": 40 }, "end": { "line": 18, "column": 44 } } } ], "range": [ 274, 311 ], "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 45 } } }, "range": [ 274, 312 ], "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 46 } } }, { "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": "x1", "range": [ 321, 323 ], "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 10 } } }, "property": { "type": "Identifier", "name": "abs", "range": [ 324, 327 ], "loc": { "start": { "line": 19, "column": 11 }, "end": { "line": 19, "column": 14 } } }, "range": [ 321, 327 ], "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 14 } } }, "arguments": [], "range": [ 321, 329 ], "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 16 } } }, "property": { "type": "Identifier", "name": "should", "range": [ 330, 336 ], "loc": { "start": { "line": 19, "column": 17 }, "end": { "line": 19, "column": 23 } } }, "range": [ 321, 336 ], "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 23 } } }, "property": { "type": "Identifier", "name": "be", "range": [ 337, 339 ], "loc": { "start": { "line": 19, "column": 24 }, "end": { "line": 19, "column": 26 } } }, "range": [ 321, 339 ], "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 26 } } }, "property": { "type": "Identifier", "name": "closeTo", "range": [ 340, 347 ], "loc": { "start": { "line": 19, "column": 27 }, "end": { "line": 19, "column": 34 } } }, "range": [ 321, 347 ], "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 34 } } }, "arguments": [ { "type": "Literal", "value": 1, "raw": "1", "range": [ 348, 349 ], "loc": { "start": { "line": 19, "column": 35 }, "end": { "line": 19, "column": 36 } } }, { "type": "Literal", "value": 0, "raw": "0", "range": [ 351, 352 ], "loc": { "start": { "line": 19, "column": 38 }, "end": { "line": 19, "column": 39 } } } ], "range": [ 321, 353 ], "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 40 } } }, "range": [ 321, 354 ], "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 41 } } } ], "range": [ 226, 360 ], "loc": { "start": { "line": 16, "column": 45 }, "end": { "line": 20, "column": 5 } } }, "generator": false, "expression": false, "range": [ 220, 360 ], "loc": { "start": { "line": 16, "column": 39 }, "end": { "line": 20, "column": 5 } } } ], "range": [ 185, 361 ], "loc": { "start": { "line": 16, "column": 4 }, "end": { "line": 20, "column": 6 } }, "_esdocTestId": 56, "_esdocTestName": "it56" }, "range": [ 185, 362 ], "loc": { "start": { "line": 16, "column": 4 }, "end": { "line": 20, "column": 7 } } }, { "type": "ExpressionStatement", "expression": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "it", "range": [ 368, 370 ], "loc": { "start": { "line": 22, "column": 4 }, "end": { "line": 22, "column": 6 } } }, "arguments": [ { "type": "Literal", "value": "should do 2d calculations", "raw": "'should do 2d calculations'", "range": [ 371, 398 ], "loc": { "start": { "line": 22, "column": 7 }, "end": { "line": 22, "column": 34 } } }, { "type": "ArrowFunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "x1", "range": [ 420, 422 ], "loc": { "start": { "line": 23, "column": 12 }, "end": { "line": 23, "column": 14 } } }, "init": { "type": "NewExpression", "callee": { "type": "Identifier", "name": "Vector", "range": [ 429, 435 ], "loc": { "start": { "line": 23, "column": 21 }, "end": { "line": 23, "column": 27 } } }, "arguments": [ { "type": "Literal", "value": 1, "raw": "1", "range": [ 436, 437 ], "loc": { "start": { "line": 23, "column": 28 }, "end": { "line": 23, "column": 29 } } }, { "type": "Literal", "value": 1, "raw": "1", "range": [ 439, 440 ], "loc": { "start": { "line": 23, "column": 31 }, "end": { "line": 23, "column": 32 } } } ], "range": [ 425, 441 ], "loc": { "start": { "line": 23, "column": 17 }, "end": { "line": 23, "column": 33 } } }, "range": [ 420, 441 ], "loc": { "start": { "line": 23, "column": 12 }, "end": { "line": 23, "column": 33 } } } ],