diff --git a/@types/undeclared.d.ts b/@types/undeclared.d.ts new file mode 100644 index 00000000..3dcc526d --- /dev/null +++ b/@types/undeclared.d.ts @@ -0,0 +1,6 @@ +declare module 'espree'; +declare module 'acorn-loose'; +declare module 'for-in'; +declare module 'define-property' { + export default function(obj: any, name: string, value: any): void; +} diff --git a/package.json b/package.json index 5fda5da8..e23378f9 100644 --- a/package.json +++ b/package.json @@ -34,25 +34,28 @@ "@babel/plugin-transform-runtime": "^7.6.2", "@commitlint/cli": "^8.2.0", "@commitlint/config-conventional": "^8.2.0", + "@types/jest": "^24.0.19", + "@types/node": "^12.11.1", + "@types/react": "^16.9.9", + "@types/react-dom": "^16.9.2", "@wessberg/rollup-plugin-ts": "^1.1.73", "builtin-modules": "^3.1.0", "enquirer": "^2.3.2", - "eslint": "^6.4.0", + "eslint": "^6.5.1", "esm": "^3.2.25", "husky": "^3.0.9", "jest": "^24.9.0", - "lerna": "^3.16.4", + "lerna": "^3.18.1", "prettier": "^1.18.2", "prettier-plugin-pkg": "^0.4.4", - "prettier-plugin-sh": "^0.2.0", - "react": "^16.10.1", - "rollup": "^1.23.1", + "prettier-plugin-sh": "^0.2.1", + "react": "^16.10.2", + "rollup": "^1.25.0", "rollup-plugin-commonjs": "^10.1.0", "rollup-plugin-json": "^4.0.0", "rollup-plugin-node-resolve": "^5.2.0", "rollup-plugin-terser": "^5.1.2", - "semver": "^6.3.0", - "typescript": "^3.7.0-beta", + "typescript": "^3.6.4", "verb": "verbose/verb#dev", "verb-generate-readme": "^0.8.0" }, @@ -69,11 +72,11 @@ }, "meta": { "build": [ - "koa-better-body" + "koa-better-body", + "parse-function" ], "bundle": [ - "@tunnckocore/execa", - "parse-function" + "@tunnckocore/execa" ] }, "renovate": { diff --git a/packages/parse-function/example.js b/packages/parse-function/example.js new file mode 100644 index 00000000..addfd59c --- /dev/null +++ b/packages/parse-function/example.js @@ -0,0 +1,41 @@ +import { parse as acornParse } from 'acorn'; +import { parseFunction } from './dist/module'; + +// `node` is an AST Node +function bobbyPlugin(node, result) { + const bobby = 'bobby'; + + return { ...result, bobby }; +} + +function barryPlugin(node, result) { + return { ...result, barry: 'barry barry' }; +} + +const result = parseFunction(bobbyPlugin.toString(), { + parse: acornParse, + plugins: [bobbyPlugin, barryPlugin], // supports array of plugins + parserOptions: {}, +}); + +console.log(result); + +/* { + name: 'bobbyPlugin', + body: "\n const bobby = 'bobby';\n\n return { ...result, bobby };\n", + args: [ 'node', 'result' ], + params: 'node, result', + defaults: { node: undefined, result: undefined }, + value: '(function bobbyPlugin(node, result) {\n const ' + + "bobby = 'bobby';\n\n return { ...result, bobby };\n" + + '})', + isValid: true, + isArrow: false, + isAsync: false, + isNamed: true, + isAnonymous: false, + isGenerator: false, + isExpression: false, + bobby: 'bobby', + barry: 'barry barry' +} */ diff --git a/packages/parse-function/package.json b/packages/parse-function/package.json index a7b8483d..095c6a6a 100644 --- a/packages/parse-function/package.json +++ b/packages/parse-function/package.json @@ -13,8 +13,8 @@ "engines": { "node": ">=8.11" }, - "main": "dist/cjs/index.js", - "module": "dist/esm/index.js", + "main": "dist/main/index.js", + "module": "dist/module/index.js", "types": "dist/types/index.d.ts", "files": [ "dist" @@ -48,7 +48,9 @@ ], "scripts": {}, "dependencies": { - "@babel/parser": "^7.6.4" + "@types/babel__core": "^7.1.3", + "@babel/parser": "^7.6.4", + "@babel/types": "^7.6.3" }, "devDependencies": { "acorn": "^7.1.0", diff --git a/packages/parse-function/src/index.js b/packages/parse-function/src/index.js deleted file mode 100644 index b757336b..00000000 --- a/packages/parse-function/src/index.js +++ /dev/null @@ -1,228 +0,0 @@ -/** - * Utilities - */ - -import utils from './utils'; - -/** - * Core plugins - */ - -import initial from './plugins/initial'; - -/** - * > Initializes with optional `opts` object which is passed directly - * to the desired parser and returns an object - * with `.use` and `.parse` methods. The default parse which - * is used is [babylon][]'s `.parseExpression` method from `v7`. - * - * ```js - * const parseFunction = require('parse-function') - * - * const app = parseFunction({ - * ecmaVersion: 2017 - * }) - * - * const fixtureFn = (a, b, c) => { - * a = b + c - * return a + 2 - * } - * - * const result = app.parse(fixtureFn) - * console.log(result) - * - * // see more - * console.log(result.name) // => null - * console.log(result.isNamed) // => false - * console.log(result.isArrow) // => true - * console.log(result.isAnonymous) // => true - * - * // array of names of the arguments - * console.log(result.args) // => ['a', 'b', 'c'] - * - * // comma-separated names of the arguments - * console.log(result.params) // => 'a, b, c' - * ``` - * - * @param {Object} `opts` optional, merged with options passed to `.parse` method - * @return {Object} `app` object with `.use` and `.parse` methods - * @name parseFunction - * @api public - */ -export default function parseFunction(opts) { - const plugins = []; - const app = { - /** - * > Parse a given `code` and returns a `result` object - * with useful properties - such as `name`, `body` and `args`. - * By default it uses Babylon parser, but you can switch it by - * passing `options.parse` - for example `options.parse: acorn.parse`. - * In the below example will show how to use `acorn` parser, instead - * of the default one. - * - * ```js - * const acorn = require('acorn') - * const parseFn = require('parse-function') - * const app = parseFn() - * - * const fn = function foo (bar, baz) { return bar * baz } - * const result = app.parse(fn, { - * parse: acorn.parse, - * ecmaVersion: 2017 - * }) - * - * console.log(result.name) // => 'foo' - * console.log(result.args) // => ['bar', 'baz'] - * console.log(result.body) // => ' return bar * baz ' - * console.log(result.isNamed) // => true - * console.log(result.isArrow) // => false - * console.log(result.isAnonymous) // => false - * console.log(result.isGenerator) // => false - * ``` - * - * @param {Function|String} `code` any kind of function or string to be parsed - * @param {Object} `options` directly passed to the parser - babylon, acorn, espree - * @param {Function} `options.parse` by default `babylon.parseExpression`, - * all `options` are passed as second argument - * to that provided function - * @return {Object} `result` see [result section](#result) for more info - * @name .parse - * @api public - */ - parse(code, options) { - const result = utils.setDefaults(code); - - if (!result.isValid) { - return result; - } - - const mergedOptions = { ...opts, ...options }; - - const isFunction = result.value.startsWith('function'); - const isAsyncFn = result.value.startsWith('async function'); - const isAsync = result.value.startsWith('async'); - const isArrow = result.value.includes('=>'); - const isAsyncArrow = isAsync && isArrow; - - const isMethod = /^\*?.+\([\s\S\w\W]*\)\s*\{/i.test(result.value); - - if (!(isFunction || isAsyncFn || isAsyncArrow) && isMethod) { - result.value = `{ ${result.value} }`; - } - - const node = utils.getNode(result, mergedOptions); - return plugins.reduce((res, fn) => fn(node, res) || res, result); - }, - - /** - * > Add a plugin `fn` function for extending the API or working on the - * AST nodes. The `fn` is immediately invoked and passed - * with `app` argument which is instance of `parseFunction()` call. - * That `fn` may return another function that - * accepts `(node, result)` signature, where `node` is an AST node - * and `result` is an object which will be returned [result](#result) - * from the `.parse` method. This retuned function is called on each - * node only when `.parse` method is called. - * - * _See [Plugins Architecture](#plugins-architecture) section._ - * - * ```js - * // plugin extending the `app` - * app.use((app) => { - * app.define(app, 'hello', (place) => `Hello ${place}!`) - * }) - * - * const hi = app.hello('World') - * console.log(hi) // => 'Hello World!' - * - * // or plugin that works on AST nodes - * app.use((app) => (node, result) => { - * if (node.type === 'ArrowFunctionExpression') { - * result.thatIsArrow = true - * } - * return result - * }) - * - * const result = app.parse((a, b) => (a + b + 123)) - * console.log(result.name) // => null - * console.log(result.isArrow) // => true - * console.log(result.thatIsArrow) // => true - * - * const result = app.parse(function foo () { return 123 }) - * console.log(result.name) // => 'foo' - * console.log(result.isArrow) // => false - * console.log(result.thatIsArrow) // => undefined - * ``` - * - * @param {Function} `fn` plugin to be called - * @return {Object} `app` instance for chaining - * @name .use - * @api public - */ - use(fn) { - const ret = fn(app); - if (typeof ret === 'function') { - plugins.push(ret); - } - return app; - }, - - /** - * > Define a non-enumerable property on an object. Just - * a convenience mirror of the [define-property][] library, - * so check out its docs. Useful to be used in plugins. - * - * ```js - * const parseFunction = require('parse-function') - * const app = parseFunction() - * - * // use it like `define-property` lib - * const obj = {} - * app.define(obj, 'hi', 'world') - * console.log(obj) // => { hi: 'world' } - * - * // or define a custom plugin that adds `.foo` property - * // to the end result, returned from `app.parse` - * app.use((app) => { - * return (node, result) => { - * // this function is called - * // only when `.parse` is called - * - * app.define(result, 'foo', 123) - * - * return result - * } - * }) - * - * // fixture function to be parsed - * const asyncFn = async (qux) => { - * const bar = await Promise.resolve(qux) - * return bar - * } - * - * const result = app.parse(asyncFn) - * - * console.log(result.name) // => null - * console.log(result.foo) // => 123 - * console.log(result.args) // => ['qux'] - * - * console.log(result.isAsync) // => true - * console.log(result.isArrow) // => true - * console.log(result.isNamed) // => false - * console.log(result.isAnonymous) // => true - * ``` - * - * @param {Object} `obj` the object on which to define the property - * @param {String} `prop` the name of the property to be defined or modified - * @param {Any} `val` the descriptor for the property being defined or modified - * @return {Object} `obj` the passed object, but modified - * @name .define - * @api public - */ - define: utils.define, - }; - - app.use(initial); - - return app; -} diff --git a/packages/parse-function/src/index.ts b/packages/parse-function/src/index.ts new file mode 100644 index 00000000..1823cfda --- /dev/null +++ b/packages/parse-function/src/index.ts @@ -0,0 +1,41 @@ +/* eslint-disable @typescript-eslint/no-explicit-any */ +import arrayify from 'arrify'; +import { parse as babelParse } from '@babel/parser'; + +import { setDefaults, getNode } from './utils'; +import { Input, Options, Plugin, Result } from './types'; + +import basePlugin from './plugins/initial'; + +// eslint-disable-next-line import/prefer-default-export +export function parseFunction(code: Input, options?: Options) { + const opts: Options = { parse: babelParse, ...options }; + const result: Result = setDefaults(code); + + if (!result.isValid) { + return result; + } + + const isFunction = result.value.startsWith('function'); + const isAsyncFn = result.value.startsWith('async function'); + const isAsync = result.value.startsWith('async'); + const isArrow = result.value.includes('=>'); + const isAsyncArrow = isAsync && isArrow; + + const isMethod = /^\*?.+\([\s\S\w\W]*\)\s*\{/i.test(result.value); + + if (!(isFunction || isAsyncFn || isAsyncArrow) && isMethod) { + result.value = `{ ${result.value} }`; + } + + const node = getNode(result, opts); + const plugins = arrayify(opts.plugins); + + return [basePlugin, ...plugins] + .filter(Boolean) + .reduce((res: any, fn: Plugin) => { + const pluginResult = fn(node, { ...res }) || res; + + return pluginResult; + }, result); +} diff --git a/packages/parse-function/src/plugins/body.js b/packages/parse-function/src/plugins/body.js deleted file mode 100644 index 547b2378..00000000 --- a/packages/parse-function/src/plugins/body.js +++ /dev/null @@ -1,24 +0,0 @@ -/* eslint-disable no-param-reassign, unicorn/consistent-function-scoping */ - -/** - * > Micro plugin to get the raw body, without the - * surrounding curly braces. It also preserves - * the whitespaces and newlines - they are original. - * - * @param {Object} node - * @param {Object} result - * @return {Object} result - * @private - */ -export default () => (node, result) => { - result.body = result.value.slice(node.body.start, node.body.end); - - const openCurly = result.body.charCodeAt(0) === 123; - const closeCurly = result.body.charCodeAt(result.body.length - 1) === 125; - - if (openCurly && closeCurly) { - result.body = result.body.slice(1, -1); - } - - return result; -}; diff --git a/packages/parse-function/src/plugins/body.ts b/packages/parse-function/src/plugins/body.ts new file mode 100644 index 00000000..4063c183 --- /dev/null +++ b/packages/parse-function/src/plugins/body.ts @@ -0,0 +1,26 @@ +/* eslint-disable no-param-reassign, @typescript-eslint/no-explicit-any */ + +import { Result } from '../types'; + +/** + * > Micro plugin to get the raw body, without the + * surrounding curly braces. It also preserves + * the whitespaces and newlines - they are original. + * + * @param node + * @param result + * @return result + * @private + */ +export default (node: any, result: Result): Result => { + let body = result.value.slice(node.body.start, node.body.end); + + const openCurly = body.charCodeAt(0) === 123; + const closeCurly = body.charCodeAt(body.length - 1) === 125; + + if (openCurly && closeCurly) { + body = body.slice(1, -1); + } + + return { ...result, body }; +}; diff --git a/packages/parse-function/src/plugins/initial.js b/packages/parse-function/src/plugins/initial.ts similarity index 60% rename from packages/parse-function/src/plugins/initial.js rename to packages/parse-function/src/plugins/initial.ts index 4537fd17..c966c007 100644 --- a/packages/parse-function/src/plugins/initial.js +++ b/packages/parse-function/src/plugins/initial.ts @@ -1,26 +1,28 @@ -/* eslint-disable no-param-reassign */ +/* eslint-disable no-param-reassign, @typescript-eslint/no-explicit-any */ -import body from './body'; -import props from './props'; -import params from './params'; +import { Result } from '../types'; + +import bodyPlugin from './body'; +import propsPlugin from './props'; +import paramsPlugin from './params'; /** * > Default plugin that handles regular functions, * arrow functions, generator functions * and ES6 object method notation. * - * @param {Object} node - * @param {Object} result - * @return {Object} resul + * @param node + * @param result + * @return resul * @private */ -export default (app) => (node, result) => { +export default (node: any, result: Result): Result => { const isFn = node.type.endsWith('FunctionExpression'); const isMethod = node.type === 'ObjectExpression'; /* istanbul ignore next */ if (!isFn && !isMethod) { - return; + return result; } node = isMethod ? node.properties[0] : node; @@ -34,10 +36,9 @@ export default (app) => (node, result) => { node.id = id; } - result = props(app)(node, result); - result = params(app)(node, result); - result = body(app)(node, result); + result = bodyPlugin(node, result); + result = propsPlugin(node, result); + result = paramsPlugin(node, result); - // eslint-disable-next-line consistent-return return result; }; diff --git a/packages/parse-function/src/plugins/params.js b/packages/parse-function/src/plugins/params.ts similarity index 78% rename from packages/parse-function/src/plugins/params.js rename to packages/parse-function/src/plugins/params.ts index 408fc337..e1dc6837 100644 --- a/packages/parse-function/src/plugins/params.js +++ b/packages/parse-function/src/plugins/params.ts @@ -1,17 +1,19 @@ -/* eslint-disable no-param-reassign, unicorn/consistent-function-scoping */ +import { Result } from '../types'; + +/* eslint-disable no-param-reassign, @typescript-eslint/no-explicit-any */ /** * > Micro plugin to visit each of the params * in the given function and collect them into * an `result.args` array and `result.params` string. * - * @param {Object} node - * @param {Object} result - * @return {Object} result + * @param node + * @param result + * @return result * @private */ -export default () => (node, result) => { - node.params.forEach((param) => { +export default (node: any, result: Result): Result => { + node.params.forEach((param: any) => { const defaultArgsName = param.type === 'AssignmentPattern' && param.left && param.left.name; diff --git a/packages/parse-function/src/plugins/props.js b/packages/parse-function/src/plugins/props.js deleted file mode 100644 index 7a19e6df..00000000 --- a/packages/parse-function/src/plugins/props.js +++ /dev/null @@ -1,32 +0,0 @@ -/** - * > Set couple of hidden properties and - * the name of the given function to - * the returned result object. Notice that - * if function is called "anonymous" then - * the `result.isAnonymous` would be `false`, because - * in reality it is named function. It would be `true` - * only when function is really anonymous and don't have - * any name. - * - * @param {Object} node - * @param {Object} result - * @return {Object} result - * @private - */ -export default (app) => (node, result) => { - app.define(result, 'isArrow', node.type.startsWith('Arrow')); - app.define(result, 'isAsync', node.async || false); - app.define(result, 'isGenerator', node.generator || false); - app.define(result, 'isExpression', node.expression || false); - app.define(result, 'isAnonymous', node.id === null); - app.define(result, 'isNamed', !result.isAnonymous); - - // if real anonymous -> set to null, - // notice that you can name you function `anonymous`, haha - // and it won't be "real" anonymous, so `isAnonymous` will be `false` - - // eslint-disable-next-line no-param-reassign - result.name = result.isAnonymous ? null : node.id.name; - - return result; -}; diff --git a/packages/parse-function/src/plugins/props.ts b/packages/parse-function/src/plugins/props.ts new file mode 100644 index 00000000..8e542fb8 --- /dev/null +++ b/packages/parse-function/src/plugins/props.ts @@ -0,0 +1,38 @@ +/* eslint-disable @typescript-eslint/no-explicit-any */ + +import { Result } from '../types'; + +/** + * > Set couple of hidden properties and + * the name of the given function to + * the returned result object. Notice that + * if function is called "anonymous" then + * the `result.isAnonymous` would be `false`, because + * in reality it is named function. It would be `true` + * only when function is really anonymous and don't have + * any name. + * + * @param node + * @param result + * @return result + * @private + */ +export default (node: any, result: Result): Result => { + const res = { + ...result, + isArrow: node.type.startsWith('Arrow'), + isAsync: node.async || false, + isGenerator: node.generator || false, + isExpression: node.expression || false, + isAnonymous: node.id === null, + isNamed: node.id !== null, + + // if real anonymous -> set to null, + // notice that you can name you function `anonymous`, haha + // and it won't be "real" anonymous, so `isAnonymous` will be `false` + + name: node.id === null ? null : node.id.name, + }; + + return res; +}; diff --git a/packages/parse-function/src/types.ts b/packages/parse-function/src/types.ts new file mode 100644 index 00000000..1baa912c --- /dev/null +++ b/packages/parse-function/src/types.ts @@ -0,0 +1,31 @@ +import { ParserOptions } from '@babel/parser'; + +// eslint-disable-next-line @typescript-eslint/no-explicit-any +type FnType = (...args: any) => any; + +export type Input = FnType | string; +// eslint-disable-next-line @typescript-eslint/no-explicit-any +export type Plugin = (node: any, result: Result) => Result | undefined; +export type Plugins = Plugin | Array; + +export interface Options { + parse?(input: string, options?: ParserOptions): import('@babel/types').File; + parserOptions?: ParserOptions; + plugins?: Plugins; +} + +export interface Result { + name: string | null; + body: string; + args: Array; + params: string; + defaults: { [key: string]: string | undefined }; + value: string; + isValid: boolean; + isArrow: boolean; + isAsync: boolean; + isNamed: boolean; + isAnonymous: boolean; + isGenerator: boolean; + isExpression: boolean; +} diff --git a/packages/parse-function/src/utils.js b/packages/parse-function/src/utils.js deleted file mode 100644 index 6bd7c1e9..00000000 --- a/packages/parse-function/src/utils.js +++ /dev/null @@ -1,85 +0,0 @@ -import arrayify from 'arrify'; -import { parseExpression } from '@babel/parser'; -import define from 'define-property'; - -const utils = {}; -utils.define = define; -utils.arrayify = arrayify; - -/** - * > Create default result object, - * and normalize incoming arguments. - * - * @param {Function|String} code - * @return {Object} result - * @private - */ -utils.setDefaults = function setDefaults(code) { - const result = { - name: null, - body: '', - args: [], - params: '', - }; - - if (typeof code === 'function') { - // eslint-disable-next-line no-param-reassign - code = code.toString('utf8'); - } - - // makes result.isValid === false - if (typeof code !== 'string') { - // eslint-disable-next-line no-param-reassign - code = ''; - } - - return utils.setHiddenDefaults(result, code || ''); -}; - -/** - * > Create hidden properties into - * the result object. - * - * @param {Object} result - * @param {Function|String} code - * @return {Object} result - * @private - */ -utils.setHiddenDefaults = function setHiddenDefaults(result, code) { - utils.define(result, 'defaults', {}); - utils.define(result, 'value', code); - utils.define(result, 'isValid', code.length > 0); - utils.define(result, 'isArrow', false); - utils.define(result, 'isAsync', false); - utils.define(result, 'isNamed', false); - utils.define(result, 'isAnonymous', false); - utils.define(result, 'isGenerator', false); - utils.define(result, 'isExpression', false); - - return result; -}; - -/** - * > Get needed AST tree, depending on what - * parse method is used. - * - * @param {Object} result - * @param {Object} opts - * @return {Object} node - * @private - */ -utils.getNode = function getNode(result, opts) { - if (typeof opts.parse === 'function') { - // eslint-disable-next-line no-param-reassign - result.value = `(${result.value})`; - - const ast = opts.parse(result.value, opts); - const body = (ast.program && ast.program.body) || ast.body; - - return body[0].expression; - } - - return parseExpression(result.value, opts); -}; - -export default utils; diff --git a/packages/parse-function/src/utils.ts b/packages/parse-function/src/utils.ts new file mode 100644 index 00000000..975a89f0 --- /dev/null +++ b/packages/parse-function/src/utils.ts @@ -0,0 +1,91 @@ +/* eslint-disable no-param-reassign */ + +import { parseExpression } from '@babel/parser'; +import { Options, Input, Result } from './types'; + +/** + * > Create default result object, + * and normalize incoming arguments. + * + * @param code + * @return result + * @private + */ +export function setDefaults(code: Input): Result { + const result = { + name: null, + body: '', + args: [], + params: '', + }; + + if (typeof code === 'function') { + code = code.toString(); + } + + // makes result.isValid === false + if (typeof code !== 'string') { + code = ''; + } + + return setHiddenDefaults(result, code || ''); +} + +/** + * > Create hidden properties into + * the result object. + * + * @param result + * @param code + * @return result + * @private + */ + +export function setHiddenDefaults( + result: /* eslint-disable @typescript-eslint/no-explicit-any */ any, + code: Input, +): Result { + result.defaults = {}; + result.value = code; + result.isValid = code.length > 0; + result.isArrow = false; + result.isAsync = false; + result.isNamed = false; + result.isAnonymous = false; + result.isGenerator = false; + result.isExpression = false; + + return result; +} + +/** + * > Get needed AST tree, depending on what + * parse method is used. + * + * @param result + * @param opts + * @return node + * @private + */ +export function getNode(result: Result, options?: Options): any { + const opts: Options = { ...options }; + if (typeof opts.parse === 'function') { + result.value = `(${result.value})`; + + const ast = opts.parse(result.value, opts.parserOptions); + + // for other parsers + // eslint-disable-next-line @typescript-eslint/ban-ts-ignore + // @ts-ignore + const astBody = ast.body; + + const body = (ast.program && ast.program.body) || astBody; + + // what the heck?! + // eslint-disable-next-line @typescript-eslint/ban-ts-ignore + // @ts-ignore + return body[0].expression; + } + + return parseExpression(result.value, opts.parserOptions); +} diff --git a/packages/parse-function/test/__snapshots__/index.js.snap b/packages/parse-function/test/__snapshots__/index.js.snap deleted file mode 100644 index 3503ea9c..00000000 --- a/packages/parse-function/test/__snapshots__/index.js.snap +++ /dev/null @@ -1,4907 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`#1 - babel (default) - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#2 - babel (default) - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#3 - babel (default) - function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#4 - babel (default) - function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#5 - babel (default) - function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#6 - babel (default) - function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#7 - babel (default) - function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#8 - babel (default) - function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#9 - babel (default) - function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#10 - babel (default) - function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#11 - babel (default) - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#12 - babel (default) - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#13 - babel (default) - function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#14 - babel (default) - function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#15 - babel (default) - function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#16 - babel (default) - function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#17 - babel (default) - function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#18 - babel (default) - function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#19 - babel (default) - function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#20 - babel (default) - function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#21 - babel (default) - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#22 - babel (default) - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#23 - babel (default) - function * namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#24 - babel (default) - function * namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#25 - babel (default) - function * namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#26 - babel (default) - function * namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#27 - babel (default) - function * namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#28 - babel (default) - function * namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#29 - babel (default) - function * namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#30 - babel (default) - function * namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#31 - babel (default) - a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#32 - babel (default) - b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#33 - babel (default) - c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#34 - babel (default) - ...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#35 - babel (default) - ) => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#36 - babel (default) - a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#37 - babel (default) - a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#38 - babel (default) - a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#39 - babel (default) - a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#40 - babel (default) - a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#41 - babel (default) - a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#42 - babel (default) - d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#43 - babel (default) - e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#44 - babel (default) - a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#45 - babel (default) - x, y, ...restArgs) => console.log({ value: x * y } 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#46 - babel (default) - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#47 - babel (default) - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#48 - babel (default) - async function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#49 - babel (default) - async function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#50 - babel (default) - async function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#51 - babel (default) - async function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#52 - babel (default) - async function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#53 - babel (default) - async function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#54 - babel (default) - async function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#55 - babel (default) - async function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#56 - babel (default) - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#57 - babel (default) - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#58 - babel (default) - async function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#59 - babel (default) - async function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#60 - babel (default) - async function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#61 - babel (default) - async function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#62 - babel (default) - async function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#63 - babel (default) - async function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#64 - babel (default) - async function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#65 - babel (default) - async function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#66 - babel (default) - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#67 - babel (default) - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#68 - babel (default) - async (c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#69 - babel (default) - async (...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#70 - babel (default) - async () => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#71 - babel (default) - async (a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#72 - babel (default) - async (a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#73 - babel (default) - async (a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#74 - babel (default) - async (a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#75 - babel (default) - async (a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#76 - babel (default) - async (a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#77 - babel (default) - async d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#78 - babel (default) - async e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#79 - babel (default) - async (a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#80 - babel (default) - async (x, y, ...restArgs) => console.log({ value: x * y } 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#81 - babel (default) - should return object with default values when invalid 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#82 - babel (default) - should have '.isValid' and few '.is*'' hidden properties 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#87 - babel (default) - should work for object methods 1`] = ` -Object { - "args": Array [ - "a", - "b", - "c", - ], - "body": " - return 123; - ", - "name": "foo", - "params": "a, b, c", -} -`; - -exports[`#87 - babel (default) - should work for object methods 2`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return () => a; - ", - "name": "bar", - "params": "a", -} -`; - -exports[`#87 - babel (default) - should work for object methods 3`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return yield a * 321; - ", - "name": "gen", - "params": "a", -} -`; - -exports[`#87 - babel (default) - should work for object methods 4`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": " return a * 3 ", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#91 - options.parse + ecmaVersion: 2019 - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#92 - options.parse + ecmaVersion: 2019 - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#93 - options.parse + ecmaVersion: 2019 - function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#94 - options.parse + ecmaVersion: 2019 - function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#95 - options.parse + ecmaVersion: 2019 - function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#96 - options.parse + ecmaVersion: 2019 - function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#97 - options.parse + ecmaVersion: 2019 - function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#98 - options.parse + ecmaVersion: 2019 - function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#99 - options.parse + ecmaVersion: 2019 - function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#100 - options.parse + ecmaVersion: 2019 - function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#101 - options.parse + ecmaVersion: 2019 - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#102 - options.parse + ecmaVersion: 2019 - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#103 - options.parse + ecmaVersion: 2019 - function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#104 - options.parse + ecmaVersion: 2019 - function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#105 - options.parse + ecmaVersion: 2019 - function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#106 - options.parse + ecmaVersion: 2019 - function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#107 - options.parse + ecmaVersion: 2019 - function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#108 - options.parse + ecmaVersion: 2019 - function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#109 - options.parse + ecmaVersion: 2019 - function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#110 - options.parse + ecmaVersion: 2019 - function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#111 - options.parse + ecmaVersion: 2019 - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#112 - options.parse + ecmaVersion: 2019 - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#113 - options.parse + ecmaVersion: 2019 - function * namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#114 - options.parse + ecmaVersion: 2019 - function * namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#115 - options.parse + ecmaVersion: 2019 - function * namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#116 - options.parse + ecmaVersion: 2019 - function * namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#117 - options.parse + ecmaVersion: 2019 - function * namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#118 - options.parse + ecmaVersion: 2019 - function * namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#119 - options.parse + ecmaVersion: 2019 - function * namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#120 - options.parse + ecmaVersion: 2019 - function * namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#121 - options.parse + ecmaVersion: 2019 - (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#122 - options.parse + ecmaVersion: 2019 - (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#123 - options.parse + ecmaVersion: 2019 - (c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#124 - options.parse + ecmaVersion: 2019 - (...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#125 - options.parse + ecmaVersion: 2019 - () => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#126 - options.parse + ecmaVersion: 2019 - (a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#127 - options.parse + ecmaVersion: 2019 - (a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#128 - options.parse + ecmaVersion: 2019 - (a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#129 - options.parse + ecmaVersion: 2019 - (a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#130 - options.parse + ecmaVersion: 2019 - (a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#131 - options.parse + ecmaVersion: 2019 - (a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#132 - options.parse + ecmaVersion: 2019 - d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#133 - options.parse + ecmaVersion: 2019 - e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#134 - options.parse + ecmaVersion: 2019 - (a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#135 - options.parse + ecmaVersion: 2019 - (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#136 - options.parse + ecmaVersion: 2019 - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#137 - options.parse + ecmaVersion: 2019 - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#138 - options.parse + ecmaVersion: 2019 - async function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#139 - options.parse + ecmaVersion: 2019 - async function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#140 - options.parse + ecmaVersion: 2019 - async function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#141 - options.parse + ecmaVersion: 2019 - async function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#142 - options.parse + ecmaVersion: 2019 - async function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#143 - options.parse + ecmaVersion: 2019 - async function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#144 - options.parse + ecmaVersion: 2019 - async function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#145 - options.parse + ecmaVersion: 2019 - async function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#146 - options.parse + ecmaVersion: 2019 - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#147 - options.parse + ecmaVersion: 2019 - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#148 - options.parse + ecmaVersion: 2019 - async function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#149 - options.parse + ecmaVersion: 2019 - async function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#150 - options.parse + ecmaVersion: 2019 - async function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#151 - options.parse + ecmaVersion: 2019 - async function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#152 - options.parse + ecmaVersion: 2019 - async function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#153 - options.parse + ecmaVersion: 2019 - async function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#154 - options.parse + ecmaVersion: 2019 - async function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#155 - options.parse + ecmaVersion: 2019 - async function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#156 - options.parse + ecmaVersion: 2019 - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#157 - options.parse + ecmaVersion: 2019 - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#158 - options.parse + ecmaVersion: 2019 - async (c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#159 - options.parse + ecmaVersion: 2019 - async (...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#160 - options.parse + ecmaVersion: 2019 - async () => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#161 - options.parse + ecmaVersion: 2019 - async (a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#162 - options.parse + ecmaVersion: 2019 - async (a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#163 - options.parse + ecmaVersion: 2019 - async (a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#164 - options.parse + ecmaVersion: 2019 - async (a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#165 - options.parse + ecmaVersion: 2019 - async (a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#166 - options.parse + ecmaVersion: 2019 - async (a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#167 - options.parse + ecmaVersion: 2019 - async d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#168 - options.parse + ecmaVersion: 2019 - async e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#169 - options.parse + ecmaVersion: 2019 - async (a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#170 - options.parse + ecmaVersion: 2019 - async (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#171 - options.parse + ecmaVersion: 2019 - should return object with default values when invalid 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#172 - options.parse + ecmaVersion: 2019 - should have '.isValid' and few '.is*'' hidden properties 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#177 - options.parse + ecmaVersion: 2019 - should work for object methods 1`] = ` -Object { - "args": Array [ - "a", - "b", - "c", - ], - "body": " - return 123; - ", - "name": "foo", - "params": "a, b, c", -} -`; - -exports[`#177 - options.parse + ecmaVersion: 2019 - should work for object methods 2`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return () => a; - ", - "name": "bar", - "params": "a", -} -`; - -exports[`#177 - options.parse + ecmaVersion: 2019 - should work for object methods 3`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return yield a * 321; - ", - "name": "gen", - "params": "a", -} -`; - -exports[`#177 - options.parse + ecmaVersion: 2019 - should work for object methods 4`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": " return a * 3 ", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#181 - acorn.parse - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#182 - acorn.parse - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#183 - acorn.parse - function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#184 - acorn.parse - function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#185 - acorn.parse - function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#186 - acorn.parse - function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#187 - acorn.parse - function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#188 - acorn.parse - function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#189 - acorn.parse - function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#190 - acorn.parse - function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#191 - acorn.parse - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#192 - acorn.parse - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#193 - acorn.parse - function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#194 - acorn.parse - function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#195 - acorn.parse - function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#196 - acorn.parse - function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#197 - acorn.parse - function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#198 - acorn.parse - function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#199 - acorn.parse - function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#200 - acorn.parse - function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#201 - acorn.parse - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#202 - acorn.parse - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#203 - acorn.parse - function * namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#204 - acorn.parse - function * namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#205 - acorn.parse - function * namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#206 - acorn.parse - function * namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#207 - acorn.parse - function * namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#208 - acorn.parse - function * namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#209 - acorn.parse - function * namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#210 - acorn.parse - function * namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#211 - acorn.parse - (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#212 - acorn.parse - (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#213 - acorn.parse - (c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#214 - acorn.parse - (...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#215 - acorn.parse - () => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#216 - acorn.parse - (a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#217 - acorn.parse - (a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#218 - acorn.parse - (a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#219 - acorn.parse - (a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#220 - acorn.parse - (a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#221 - acorn.parse - (a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#222 - acorn.parse - d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#223 - acorn.parse - e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#224 - acorn.parse - (a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#225 - acorn.parse - (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#226 - acorn.parse - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#227 - acorn.parse - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#228 - acorn.parse - async function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#229 - acorn.parse - async function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#230 - acorn.parse - async function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#231 - acorn.parse - async function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#232 - acorn.parse - async function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#233 - acorn.parse - async function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#234 - acorn.parse - async function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#235 - acorn.parse - async function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#236 - acorn.parse - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#237 - acorn.parse - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#238 - acorn.parse - async function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#239 - acorn.parse - async function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#240 - acorn.parse - async function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#241 - acorn.parse - async function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#242 - acorn.parse - async function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#243 - acorn.parse - async function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#244 - acorn.parse - async function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#245 - acorn.parse - async function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#246 - acorn.parse - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#247 - acorn.parse - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#248 - acorn.parse - async (c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#249 - acorn.parse - async (...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#250 - acorn.parse - async () => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#251 - acorn.parse - async (a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#252 - acorn.parse - async (a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#253 - acorn.parse - async (a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#254 - acorn.parse - async (a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#255 - acorn.parse - async (a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#256 - acorn.parse - async (a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#257 - acorn.parse - async d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#258 - acorn.parse - async e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#259 - acorn.parse - async (a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#260 - acorn.parse - async (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#261 - acorn.parse - should return object with default values when invalid 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#262 - acorn.parse - should have '.isValid' and few '.is*'' hidden properties 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#267 - acorn.parse - should work for object methods 1`] = ` -Object { - "args": Array [ - "a", - "b", - "c", - ], - "body": " - return 123; - ", - "name": "foo", - "params": "a, b, c", -} -`; - -exports[`#267 - acorn.parse - should work for object methods 2`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return () => a; - ", - "name": "bar", - "params": "a", -} -`; - -exports[`#267 - acorn.parse - should work for object methods 3`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return yield a * 321; - ", - "name": "gen", - "params": "a", -} -`; - -exports[`#267 - acorn.parse - should work for object methods 4`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": " return a * 3 ", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#271 - acorn loose - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#272 - acorn loose - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#273 - acorn loose - function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#274 - acorn loose - function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#275 - acorn loose - function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#276 - acorn loose - function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#277 - acorn loose - function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#278 - acorn loose - function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#279 - acorn loose - function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#280 - acorn loose - function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#281 - acorn loose - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#282 - acorn loose - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#283 - acorn loose - function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#284 - acorn loose - function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#285 - acorn loose - function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#286 - acorn loose - function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#287 - acorn loose - function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#288 - acorn loose - function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#289 - acorn loose - function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#290 - acorn loose - function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#291 - acorn loose - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#292 - acorn loose - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#293 - acorn loose - function * namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#294 - acorn loose - function * namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#295 - acorn loose - function * namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#296 - acorn loose - function * namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#297 - acorn loose - function * namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#298 - acorn loose - function * namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#299 - acorn loose - function * namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#300 - acorn loose - function * namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#301 - acorn loose - (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#302 - acorn loose - (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#303 - acorn loose - (c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#304 - acorn loose - (...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#305 - acorn loose - () => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#306 - acorn loose - (a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#307 - acorn loose - (a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#308 - acorn loose - (a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#309 - acorn loose - (a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#310 - acorn loose - (a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#311 - acorn loose - (a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#312 - acorn loose - d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#313 - acorn loose - e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#314 - acorn loose - (a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#315 - acorn loose - (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#316 - acorn loose - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#317 - acorn loose - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#318 - acorn loose - async function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#319 - acorn loose - async function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#320 - acorn loose - async function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#321 - acorn loose - async function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#322 - acorn loose - async function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#323 - acorn loose - async function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#324 - acorn loose - async function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#325 - acorn loose - async function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#326 - acorn loose - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#327 - acorn loose - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#328 - acorn loose - async function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#329 - acorn loose - async function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#330 - acorn loose - async function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#331 - acorn loose - async function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#332 - acorn loose - async function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#333 - acorn loose - async function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#334 - acorn loose - async function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#335 - acorn loose - async function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#336 - acorn loose - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#337 - acorn loose - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#338 - acorn loose - async (c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#339 - acorn loose - async (...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#340 - acorn loose - async () => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#341 - acorn loose - async (a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#342 - acorn loose - async (a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#343 - acorn loose - async (a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#344 - acorn loose - async (a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#345 - acorn loose - async (a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#346 - acorn loose - async (a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#347 - acorn loose - async d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#348 - acorn loose - async e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#349 - acorn loose - async (a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#350 - acorn loose - async (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#351 - acorn loose - should return object with default values when invalid 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#352 - acorn loose - should have '.isValid' and few '.is*'' hidden properties 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#357 - acorn loose - should work for object methods 1`] = ` -Object { - "args": Array [ - "a", - "b", - "c", - ], - "body": " - return 123; - ", - "name": "foo", - "params": "a, b, c", -} -`; - -exports[`#357 - acorn loose - should work for object methods 2`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return () => a; - ", - "name": "bar", - "params": "a", -} -`; - -exports[`#357 - acorn loose - should work for object methods 3`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return yield a * 321; - ", - "name": "gen", - "params": "a", -} -`; - -exports[`#357 - acorn loose - should work for object methods 4`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": " return a * 3 ", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#361 - espree.parse - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#362 - espree.parse - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#363 - espree.parse - function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#364 - espree.parse - function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#365 - espree.parse - function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#366 - espree.parse - function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#367 - espree.parse - function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#368 - espree.parse - function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#369 - espree.parse - function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#370 - espree.parse - function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#371 - espree.parse - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#372 - espree.parse - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#373 - espree.parse - function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#374 - espree.parse - function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#375 - espree.parse - function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#376 - espree.parse - function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#377 - espree.parse - function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#378 - espree.parse - function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#379 - espree.parse - function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#380 - espree.parse - function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#381 - espree.parse - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#382 - espree.parse - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#383 - espree.parse - function * namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#384 - espree.parse - function * namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#385 - espree.parse - function * namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#386 - espree.parse - function * namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#387 - espree.parse - function * namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#388 - espree.parse - function * namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#389 - espree.parse - function * namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#390 - espree.parse - function * namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#391 - espree.parse - (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#392 - espree.parse - (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#393 - espree.parse - (c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#394 - espree.parse - (...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#395 - espree.parse - () => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#396 - espree.parse - (a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#397 - espree.parse - (a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#398 - espree.parse - (a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#399 - espree.parse - (a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#400 - espree.parse - (a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#401 - espree.parse - (a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#402 - espree.parse - d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#403 - espree.parse - e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#404 - espree.parse - (a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#405 - espree.parse - (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#406 - espree.parse - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#407 - espree.parse - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#408 - espree.parse - async function (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#409 - espree.parse - async function (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#410 - espree.parse - async function () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#411 - espree.parse - async function (a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#412 - espree.parse - async function (a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#413 - espree.parse - async function (a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#414 - espree.parse - async function (a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#415 - espree.parse - async function (a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#416 - espree.parse - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`#417 - espree.parse - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": "namedFn", - "params": "b, callback, restArgs", -} -`; - -exports[`#418 - espree.parse - async function namedFn (c) {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": "namedFn", - "params": "c", -} -`; - -exports[`#419 - espree.parse - async function namedFn (...restArgs) {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": "namedFn", - "params": "restArgs", -} -`; - -exports[`#420 - espree.parse - async function namedFn () {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": "namedFn", - "params": "", -} -`; - -exports[`#421 - espree.parse - async function namedFn(a = (true, false)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#422 - espree.parse - async function namedFn(a = (true, null)) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#423 - espree.parse - async function namedFn(a = (true, "bar")) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#424 - espree.parse - async function namedFn(a, b = (i++, true)) {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": "namedFn", - "params": "a, b", -} -`; - -exports[`#425 - espree.parse - async function namedFn(a = 1) {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": "namedFn", - "params": "a", -} -`; - -exports[`#426 - espree.parse - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": "return a * 3", - "name": null, - "params": "a, cb, restArgs", -} -`; - -exports[`#427 - espree.parse - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` -Object { - "args": Array [ - "b", - "callback", - "restArgs", - ], - "body": "callback(null, b + 3)", - "name": null, - "params": "b, callback, restArgs", -} -`; - -exports[`#428 - espree.parse - async (c) => {return c * 3} 1`] = ` -Object { - "args": Array [ - "c", - ], - "body": "return c * 3", - "name": null, - "params": "c", -} -`; - -exports[`#429 - espree.parse - async (...restArgs) => {return 321} 1`] = ` -Object { - "args": Array [ - "restArgs", - ], - "body": "return 321", - "name": null, - "params": "restArgs", -} -`; - -exports[`#430 - espree.parse - async () => {} 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#431 - espree.parse - async (a = (true, false)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#432 - espree.parse - async (a = (true, null)) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#433 - espree.parse - async (a = (true, "bar")) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#434 - espree.parse - async (a, b = (i++, true)) => {} 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "", - "name": null, - "params": "a, b", -} -`; - -exports[`#435 - espree.parse - async (a = 1) => {} 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "", - "name": null, - "params": "a", -} -`; - -exports[`#436 - espree.parse - async (a) => a * 3 * a 1`] = ` -Object { - "args": Array [ - "a", - ], - "body": "a * 3 * a", - "name": null, - "params": "a", -} -`; - -exports[`#437 - espree.parse - async d => d * 355 * d 1`] = ` -Object { - "args": Array [ - "d", - ], - "body": "d * 355 * d", - "name": null, - "params": "d", -} -`; - -exports[`#438 - espree.parse - async e => {return e + 5235 / e} 1`] = ` -Object { - "args": Array [ - "e", - ], - "body": "return e + 5235 / e", - "name": null, - "params": "e", -} -`; - -exports[`#439 - espree.parse - async (a, b) => a + 3 + b 1`] = ` -Object { - "args": Array [ - "a", - "b", - ], - "body": "a + 3 + b", - "name": null, - "params": "a, b", -} -`; - -exports[`#440 - espree.parse - async (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` -Object { - "args": Array [ - "x", - "y", - "restArgs", - ], - "body": "console.log({ value: x * y })", - "name": null, - "params": "x, y, restArgs", -} -`; - -exports[`#441 - espree.parse - should return object with default values when invalid 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#442 - espree.parse - should have '.isValid' and few '.is*'' hidden properties 1`] = ` -Object { - "args": Array [], - "body": "", - "name": null, - "params": "", -} -`; - -exports[`#447 - espree.parse - should work for object methods 1`] = ` -Object { - "args": Array [ - "a", - "b", - "c", - ], - "body": " - return 123; - ", - "name": "foo", - "params": "a, b, c", -} -`; - -exports[`#447 - espree.parse - should work for object methods 2`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return () => a; - ", - "name": "bar", - "params": "a", -} -`; - -exports[`#447 - espree.parse - should work for object methods 3`] = ` -Object { - "args": Array [ - "a", - ], - "body": " - return yield a * 321; - ", - "name": "gen", - "params": "a", -} -`; - -exports[`#447 - espree.parse - should work for object methods 4`] = ` -Object { - "args": Array [ - "a", - "cb", - "restArgs", - ], - "body": " return a * 3 ", - "name": "namedFn", - "params": "a, cb, restArgs", -} -`; - -exports[`should work with an async arrow function with an \`if\` statement 1`] = ` -Object { - "args": Array [ - "v", - ], - "body": " if (v) {} ", - "name": null, - "params": "v", -} -`; diff --git a/packages/parse-function/test/__snapshots__/index.ts.snap b/packages/parse-function/test/__snapshots__/index.ts.snap new file mode 100644 index 00000000..1220d83e --- /dev/null +++ b/packages/parse-function/test/__snapshots__/index.ts.snap @@ -0,0 +1,9813 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`#1 - babel (default) - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#2 - babel (default) - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#3 - babel (default) - function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(function (c) {return c * 3})", +} +`; + +exports[`#4 - babel (default) - function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(function (...restArgs) {return 321})", +} +`; + +exports[`#5 - babel (default) - function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(function () {})", +} +`; + +exports[`#6 - babel (default) - function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, false)) {})", +} +`; + +exports[`#7 - babel (default) - function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, null)) {})", +} +`; + +exports[`#8 - babel (default) - function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#9 - babel (default) - function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(function (a, b = (i++, true)) {})", +} +`; + +exports[`#10 - babel (default) - function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = 1) {})", +} +`; + +exports[`#11 - babel (default) - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#12 - babel (default) - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#13 - babel (default) - function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function namedFn (c) {return c * 3})", +} +`; + +exports[`#14 - babel (default) - function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#15 - babel (default) - function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function namedFn () {})", +} +`; + +exports[`#16 - babel (default) - function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, false)) {})", +} +`; + +exports[`#17 - babel (default) - function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, null)) {})", +} +`; + +exports[`#18 - babel (default) - function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#19 - babel (default) - function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#20 - babel (default) - function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = 1) {})", +} +`; + +exports[`#21 - babel (default) - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function * namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#22 - babel (default) - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#23 - babel (default) - function * namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function * namedFn (c) {return c * 3})", +} +`; + +exports[`#24 - babel (default) - function * namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function * namedFn (...restArgs) {return 321})", +} +`; + +exports[`#25 - babel (default) - function * namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function * namedFn () {})", +} +`; + +exports[`#26 - babel (default) - function * namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, false)) {})", +} +`; + +exports[`#27 - babel (default) - function * namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, null)) {})", +} +`; + +exports[`#28 - babel (default) - function * namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#29 - babel (default) - function * namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function * namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#30 - babel (default) - function * namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = 1) {})", +} +`; + +exports[`#31 - babel (default) - (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "((a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#32 - babel (default) - (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "((b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#33 - babel (default) - (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "((c) => {return c * 3})", +} +`; + +exports[`#34 - babel (default) - (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "((...restArgs) => {return 321})", +} +`; + +exports[`#35 - babel (default) - () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(() => {})", +} +`; + +exports[`#36 - babel (default) - (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, false)) => {})", +} +`; + +exports[`#37 - babel (default) - (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, null)) => {})", +} +`; + +exports[`#38 - babel (default) - (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#39 - babel (default) - (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b = (i++, true)) => {})", +} +`; + +exports[`#40 - babel (default) - (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = 1) => {})", +} +`; + +exports[`#41 - babel (default) - (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a) => a * 3 * a)", +} +`; + +exports[`#42 - babel (default) - d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(d => d * 355 * d)", +} +`; + +exports[`#43 - babel (default) - e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(e => {return e + 5235 / e})", +} +`; + +exports[`#44 - babel (default) - (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b) => a + 3 + b)", +} +`; + +exports[`#45 - babel (default) - (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "((x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#46 - babel (default) - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#47 - babel (default) - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#48 - babel (default) - async function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async function (c) {return c * 3})", +} +`; + +exports[`#49 - babel (default) - async function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async function (...restArgs) {return 321})", +} +`; + +exports[`#50 - babel (default) - async function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async function () {})", +} +`; + +exports[`#51 - babel (default) - async function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, false)) {})", +} +`; + +exports[`#52 - babel (default) - async function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, null)) {})", +} +`; + +exports[`#53 - babel (default) - async function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#54 - babel (default) - async function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async function (a, b = (i++, true)) {})", +} +`; + +exports[`#55 - babel (default) - async function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = 1) {})", +} +`; + +exports[`#56 - babel (default) - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(async function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#57 - babel (default) - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#58 - babel (default) - async function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(async function namedFn (c) {return c * 3})", +} +`; + +exports[`#59 - babel (default) - async function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(async function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#60 - babel (default) - async function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(async function namedFn () {})", +} +`; + +exports[`#61 - babel (default) - async function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, false)) {})", +} +`; + +exports[`#62 - babel (default) - async function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, null)) {})", +} +`; + +exports[`#63 - babel (default) - async function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#64 - babel (default) - async function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(async function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#65 - babel (default) - async function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = 1) {})", +} +`; + +exports[`#66 - babel (default) - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#67 - babel (default) - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async (b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#68 - babel (default) - async (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async (c) => {return c * 3})", +} +`; + +exports[`#69 - babel (default) - async (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async (...restArgs) => {return 321})", +} +`; + +exports[`#70 - babel (default) - async () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async () => {})", +} +`; + +exports[`#71 - babel (default) - async (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, false)) => {})", +} +`; + +exports[`#72 - babel (default) - async (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, null)) => {})", +} +`; + +exports[`#73 - babel (default) - async (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#74 - babel (default) - async (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b = (i++, true)) => {})", +} +`; + +exports[`#75 - babel (default) - async (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = 1) => {})", +} +`; + +exports[`#76 - babel (default) - async (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a) => a * 3 * a)", +} +`; + +exports[`#77 - babel (default) - async d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(async d => d * 355 * d)", +} +`; + +exports[`#78 - babel (default) - async e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(async e => {return e + 5235 / e})", +} +`; + +exports[`#79 - babel (default) - async (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b) => a + 3 + b)", +} +`; + +exports[`#80 - babel (default) - async (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "(async (x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#81 - babel (default) - should return object with default values when invalid 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#82 - babel (default) - should have '.isValid' and few '.is*'' hidden properties 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#87 - babel (default) - should work for object methods 1`] = ` +Object { + "args": Array [ + "a", + "b", + "c", + ], + "body": " + return a + b + c; + ", + "defaults": Object { + "a": undefined, + "b": undefined, + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "foo", + "params": "a, b, c", + "value": "({ foo(a, b, c) { + return a + b + c; + } })", +} +`; + +exports[`#87 - babel (default) - should work for object methods 2`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return () => a; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "bar", + "params": "a", + "value": "({ bar(a) { + return () => a; + } })", +} +`; + +exports[`#87 - babel (default) - should work for object methods 3`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return yield a * 321; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "gen", + "params": "a", + "value": "({ *gen(a) { + return yield a * 321; + } })", +} +`; + +exports[`#87 - babel (default) - should work for object methods 4`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": " return a * 3 ", + "defaults": Object { + "a": "{foo: 'ba)r', baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "({ namedFn (a = {foo: 'ba)r', baz: 123}, cb, ...restArgs) { return a * 3 } })", +} +`; + +exports[`#91 - options.parse - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#92 - options.parse - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#93 - options.parse - function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(function (c) {return c * 3})", +} +`; + +exports[`#94 - options.parse - function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(function (...restArgs) {return 321})", +} +`; + +exports[`#95 - options.parse - function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(function () {})", +} +`; + +exports[`#96 - options.parse - function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, false)) {})", +} +`; + +exports[`#97 - options.parse - function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, null)) {})", +} +`; + +exports[`#98 - options.parse - function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#99 - options.parse - function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(function (a, b = (i++, true)) {})", +} +`; + +exports[`#100 - options.parse - function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = 1) {})", +} +`; + +exports[`#101 - options.parse - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#102 - options.parse - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#103 - options.parse - function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function namedFn (c) {return c * 3})", +} +`; + +exports[`#104 - options.parse - function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#105 - options.parse - function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function namedFn () {})", +} +`; + +exports[`#106 - options.parse - function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, false)) {})", +} +`; + +exports[`#107 - options.parse - function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, null)) {})", +} +`; + +exports[`#108 - options.parse - function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#109 - options.parse - function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#110 - options.parse - function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = 1) {})", +} +`; + +exports[`#111 - options.parse - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function * namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#112 - options.parse - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#113 - options.parse - function * namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function * namedFn (c) {return c * 3})", +} +`; + +exports[`#114 - options.parse - function * namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function * namedFn (...restArgs) {return 321})", +} +`; + +exports[`#115 - options.parse - function * namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function * namedFn () {})", +} +`; + +exports[`#116 - options.parse - function * namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, false)) {})", +} +`; + +exports[`#117 - options.parse - function * namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, null)) {})", +} +`; + +exports[`#118 - options.parse - function * namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#119 - options.parse - function * namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function * namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#120 - options.parse - function * namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = 1) {})", +} +`; + +exports[`#121 - options.parse - (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "((a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#122 - options.parse - (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "((b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#123 - options.parse - (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "((c) => {return c * 3})", +} +`; + +exports[`#124 - options.parse - (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "((...restArgs) => {return 321})", +} +`; + +exports[`#125 - options.parse - () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(() => {})", +} +`; + +exports[`#126 - options.parse - (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, false)) => {})", +} +`; + +exports[`#127 - options.parse - (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, null)) => {})", +} +`; + +exports[`#128 - options.parse - (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#129 - options.parse - (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b = (i++, true)) => {})", +} +`; + +exports[`#130 - options.parse - (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = 1) => {})", +} +`; + +exports[`#131 - options.parse - (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a) => a * 3 * a)", +} +`; + +exports[`#132 - options.parse - d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(d => d * 355 * d)", +} +`; + +exports[`#133 - options.parse - e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(e => {return e + 5235 / e})", +} +`; + +exports[`#134 - options.parse - (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b) => a + 3 + b)", +} +`; + +exports[`#135 - options.parse - (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "((x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#136 - options.parse - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#137 - options.parse - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#138 - options.parse - async function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async function (c) {return c * 3})", +} +`; + +exports[`#139 - options.parse - async function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async function (...restArgs) {return 321})", +} +`; + +exports[`#140 - options.parse - async function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async function () {})", +} +`; + +exports[`#141 - options.parse - async function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, false)) {})", +} +`; + +exports[`#142 - options.parse - async function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, null)) {})", +} +`; + +exports[`#143 - options.parse - async function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#144 - options.parse - async function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async function (a, b = (i++, true)) {})", +} +`; + +exports[`#145 - options.parse - async function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = 1) {})", +} +`; + +exports[`#146 - options.parse - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(async function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#147 - options.parse - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#148 - options.parse - async function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(async function namedFn (c) {return c * 3})", +} +`; + +exports[`#149 - options.parse - async function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(async function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#150 - options.parse - async function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(async function namedFn () {})", +} +`; + +exports[`#151 - options.parse - async function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, false)) {})", +} +`; + +exports[`#152 - options.parse - async function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, null)) {})", +} +`; + +exports[`#153 - options.parse - async function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#154 - options.parse - async function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(async function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#155 - options.parse - async function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = 1) {})", +} +`; + +exports[`#156 - options.parse - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#157 - options.parse - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async (b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#158 - options.parse - async (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async (c) => {return c * 3})", +} +`; + +exports[`#159 - options.parse - async (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async (...restArgs) => {return 321})", +} +`; + +exports[`#160 - options.parse - async () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async () => {})", +} +`; + +exports[`#161 - options.parse - async (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, false)) => {})", +} +`; + +exports[`#162 - options.parse - async (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, null)) => {})", +} +`; + +exports[`#163 - options.parse - async (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#164 - options.parse - async (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b = (i++, true)) => {})", +} +`; + +exports[`#165 - options.parse - async (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = 1) => {})", +} +`; + +exports[`#166 - options.parse - async (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a) => a * 3 * a)", +} +`; + +exports[`#167 - options.parse - async d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(async d => d * 355 * d)", +} +`; + +exports[`#168 - options.parse - async e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(async e => {return e + 5235 / e})", +} +`; + +exports[`#169 - options.parse - async (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b) => a + 3 + b)", +} +`; + +exports[`#170 - options.parse - async (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "(async (x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#171 - options.parse - should return object with default values when invalid 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#172 - options.parse - should have '.isValid' and few '.is*'' hidden properties 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#177 - options.parse - should work for object methods 1`] = ` +Object { + "args": Array [ + "a", + "b", + "c", + ], + "body": " + return a + b + c; + ", + "defaults": Object { + "a": undefined, + "b": undefined, + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "foo", + "params": "a, b, c", + "value": "({ foo(a, b, c) { + return a + b + c; + } })", +} +`; + +exports[`#177 - options.parse - should work for object methods 2`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return () => a; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "bar", + "params": "a", + "value": "({ bar(a) { + return () => a; + } })", +} +`; + +exports[`#177 - options.parse - should work for object methods 3`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return yield a * 321; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "gen", + "params": "a", + "value": "({ *gen(a) { + return yield a * 321; + } })", +} +`; + +exports[`#177 - options.parse - should work for object methods 4`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": " return a * 3 ", + "defaults": Object { + "a": "{foo: 'ba)r', baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "({ namedFn (a = {foo: 'ba)r', baz: 123}, cb, ...restArgs) { return a * 3 } })", +} +`; + +exports[`#181 - acorn.parse - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#182 - acorn.parse - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#183 - acorn.parse - function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(function (c) {return c * 3})", +} +`; + +exports[`#184 - acorn.parse - function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(function (...restArgs) {return 321})", +} +`; + +exports[`#185 - acorn.parse - function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(function () {})", +} +`; + +exports[`#186 - acorn.parse - function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, false)) {})", +} +`; + +exports[`#187 - acorn.parse - function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, null)) {})", +} +`; + +exports[`#188 - acorn.parse - function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#189 - acorn.parse - function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(function (a, b = (i++, true)) {})", +} +`; + +exports[`#190 - acorn.parse - function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = 1) {})", +} +`; + +exports[`#191 - acorn.parse - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#192 - acorn.parse - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#193 - acorn.parse - function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function namedFn (c) {return c * 3})", +} +`; + +exports[`#194 - acorn.parse - function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#195 - acorn.parse - function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function namedFn () {})", +} +`; + +exports[`#196 - acorn.parse - function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, false)) {})", +} +`; + +exports[`#197 - acorn.parse - function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, null)) {})", +} +`; + +exports[`#198 - acorn.parse - function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#199 - acorn.parse - function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#200 - acorn.parse - function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = 1) {})", +} +`; + +exports[`#201 - acorn.parse - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function * namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#202 - acorn.parse - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#203 - acorn.parse - function * namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function * namedFn (c) {return c * 3})", +} +`; + +exports[`#204 - acorn.parse - function * namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function * namedFn (...restArgs) {return 321})", +} +`; + +exports[`#205 - acorn.parse - function * namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function * namedFn () {})", +} +`; + +exports[`#206 - acorn.parse - function * namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, false)) {})", +} +`; + +exports[`#207 - acorn.parse - function * namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, null)) {})", +} +`; + +exports[`#208 - acorn.parse - function * namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#209 - acorn.parse - function * namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function * namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#210 - acorn.parse - function * namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = 1) {})", +} +`; + +exports[`#211 - acorn.parse - (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "((a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#212 - acorn.parse - (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "((b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#213 - acorn.parse - (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "((c) => {return c * 3})", +} +`; + +exports[`#214 - acorn.parse - (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "((...restArgs) => {return 321})", +} +`; + +exports[`#215 - acorn.parse - () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(() => {})", +} +`; + +exports[`#216 - acorn.parse - (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, false)) => {})", +} +`; + +exports[`#217 - acorn.parse - (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, null)) => {})", +} +`; + +exports[`#218 - acorn.parse - (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#219 - acorn.parse - (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b = (i++, true)) => {})", +} +`; + +exports[`#220 - acorn.parse - (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = 1) => {})", +} +`; + +exports[`#221 - acorn.parse - (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a) => a * 3 * a)", +} +`; + +exports[`#222 - acorn.parse - d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(d => d * 355 * d)", +} +`; + +exports[`#223 - acorn.parse - e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(e => {return e + 5235 / e})", +} +`; + +exports[`#224 - acorn.parse - (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b) => a + 3 + b)", +} +`; + +exports[`#225 - acorn.parse - (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "((x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#226 - acorn.parse - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#227 - acorn.parse - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#228 - acorn.parse - async function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async function (c) {return c * 3})", +} +`; + +exports[`#229 - acorn.parse - async function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async function (...restArgs) {return 321})", +} +`; + +exports[`#230 - acorn.parse - async function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async function () {})", +} +`; + +exports[`#231 - acorn.parse - async function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, false)) {})", +} +`; + +exports[`#232 - acorn.parse - async function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, null)) {})", +} +`; + +exports[`#233 - acorn.parse - async function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#234 - acorn.parse - async function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async function (a, b = (i++, true)) {})", +} +`; + +exports[`#235 - acorn.parse - async function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = 1) {})", +} +`; + +exports[`#236 - acorn.parse - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(async function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#237 - acorn.parse - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#238 - acorn.parse - async function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(async function namedFn (c) {return c * 3})", +} +`; + +exports[`#239 - acorn.parse - async function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(async function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#240 - acorn.parse - async function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(async function namedFn () {})", +} +`; + +exports[`#241 - acorn.parse - async function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, false)) {})", +} +`; + +exports[`#242 - acorn.parse - async function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, null)) {})", +} +`; + +exports[`#243 - acorn.parse - async function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#244 - acorn.parse - async function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(async function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#245 - acorn.parse - async function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = 1) {})", +} +`; + +exports[`#246 - acorn.parse - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#247 - acorn.parse - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async (b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#248 - acorn.parse - async (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async (c) => {return c * 3})", +} +`; + +exports[`#249 - acorn.parse - async (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async (...restArgs) => {return 321})", +} +`; + +exports[`#250 - acorn.parse - async () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async () => {})", +} +`; + +exports[`#251 - acorn.parse - async (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, false)) => {})", +} +`; + +exports[`#252 - acorn.parse - async (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, null)) => {})", +} +`; + +exports[`#253 - acorn.parse - async (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#254 - acorn.parse - async (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b = (i++, true)) => {})", +} +`; + +exports[`#255 - acorn.parse - async (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = 1) => {})", +} +`; + +exports[`#256 - acorn.parse - async (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a) => a * 3 * a)", +} +`; + +exports[`#257 - acorn.parse - async d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(async d => d * 355 * d)", +} +`; + +exports[`#258 - acorn.parse - async e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(async e => {return e + 5235 / e})", +} +`; + +exports[`#259 - acorn.parse - async (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b) => a + 3 + b)", +} +`; + +exports[`#260 - acorn.parse - async (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "(async (x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#261 - acorn.parse - should return object with default values when invalid 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#262 - acorn.parse - should have '.isValid' and few '.is*'' hidden properties 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#267 - acorn.parse - should work for object methods 1`] = ` +Object { + "args": Array [ + "a", + "b", + "c", + ], + "body": " + return a + b + c; + ", + "defaults": Object { + "a": undefined, + "b": undefined, + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "foo", + "params": "a, b, c", + "value": "({ foo(a, b, c) { + return a + b + c; + } })", +} +`; + +exports[`#267 - acorn.parse - should work for object methods 2`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return () => a; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "bar", + "params": "a", + "value": "({ bar(a) { + return () => a; + } })", +} +`; + +exports[`#267 - acorn.parse - should work for object methods 3`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return yield a * 321; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "gen", + "params": "a", + "value": "({ *gen(a) { + return yield a * 321; + } })", +} +`; + +exports[`#267 - acorn.parse - should work for object methods 4`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": " return a * 3 ", + "defaults": Object { + "a": "{foo: 'ba)r', baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "({ namedFn (a = {foo: 'ba)r', baz: 123}, cb, ...restArgs) { return a * 3 } })", +} +`; + +exports[`#271 - acorn loose - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#272 - acorn loose - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#273 - acorn loose - function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(function (c) {return c * 3})", +} +`; + +exports[`#274 - acorn loose - function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(function (...restArgs) {return 321})", +} +`; + +exports[`#275 - acorn loose - function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(function () {})", +} +`; + +exports[`#276 - acorn loose - function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, false)) {})", +} +`; + +exports[`#277 - acorn loose - function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, null)) {})", +} +`; + +exports[`#278 - acorn loose - function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#279 - acorn loose - function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(function (a, b = (i++, true)) {})", +} +`; + +exports[`#280 - acorn loose - function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = 1) {})", +} +`; + +exports[`#281 - acorn loose - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#282 - acorn loose - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#283 - acorn loose - function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function namedFn (c) {return c * 3})", +} +`; + +exports[`#284 - acorn loose - function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#285 - acorn loose - function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function namedFn () {})", +} +`; + +exports[`#286 - acorn loose - function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, false)) {})", +} +`; + +exports[`#287 - acorn loose - function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, null)) {})", +} +`; + +exports[`#288 - acorn loose - function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#289 - acorn loose - function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#290 - acorn loose - function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = 1) {})", +} +`; + +exports[`#291 - acorn loose - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function * namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#292 - acorn loose - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#293 - acorn loose - function * namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function * namedFn (c) {return c * 3})", +} +`; + +exports[`#294 - acorn loose - function * namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function * namedFn (...restArgs) {return 321})", +} +`; + +exports[`#295 - acorn loose - function * namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function * namedFn () {})", +} +`; + +exports[`#296 - acorn loose - function * namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, false)) {})", +} +`; + +exports[`#297 - acorn loose - function * namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, null)) {})", +} +`; + +exports[`#298 - acorn loose - function * namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#299 - acorn loose - function * namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function * namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#300 - acorn loose - function * namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = 1) {})", +} +`; + +exports[`#301 - acorn loose - (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "((a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#302 - acorn loose - (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "((b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#303 - acorn loose - (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "((c) => {return c * 3})", +} +`; + +exports[`#304 - acorn loose - (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "((...restArgs) => {return 321})", +} +`; + +exports[`#305 - acorn loose - () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(() => {})", +} +`; + +exports[`#306 - acorn loose - (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, false)) => {})", +} +`; + +exports[`#307 - acorn loose - (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, null)) => {})", +} +`; + +exports[`#308 - acorn loose - (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#309 - acorn loose - (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b = (i++, true)) => {})", +} +`; + +exports[`#310 - acorn loose - (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = 1) => {})", +} +`; + +exports[`#311 - acorn loose - (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a) => a * 3 * a)", +} +`; + +exports[`#312 - acorn loose - d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(d => d * 355 * d)", +} +`; + +exports[`#313 - acorn loose - e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(e => {return e + 5235 / e})", +} +`; + +exports[`#314 - acorn loose - (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b) => a + 3 + b)", +} +`; + +exports[`#315 - acorn loose - (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "((x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#316 - acorn loose - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#317 - acorn loose - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#318 - acorn loose - async function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async function (c) {return c * 3})", +} +`; + +exports[`#319 - acorn loose - async function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async function (...restArgs) {return 321})", +} +`; + +exports[`#320 - acorn loose - async function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async function () {})", +} +`; + +exports[`#321 - acorn loose - async function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, false)) {})", +} +`; + +exports[`#322 - acorn loose - async function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, null)) {})", +} +`; + +exports[`#323 - acorn loose - async function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#324 - acorn loose - async function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async function (a, b = (i++, true)) {})", +} +`; + +exports[`#325 - acorn loose - async function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = 1) {})", +} +`; + +exports[`#326 - acorn loose - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(async function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#327 - acorn loose - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#328 - acorn loose - async function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(async function namedFn (c) {return c * 3})", +} +`; + +exports[`#329 - acorn loose - async function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(async function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#330 - acorn loose - async function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(async function namedFn () {})", +} +`; + +exports[`#331 - acorn loose - async function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, false)) {})", +} +`; + +exports[`#332 - acorn loose - async function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, null)) {})", +} +`; + +exports[`#333 - acorn loose - async function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#334 - acorn loose - async function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(async function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#335 - acorn loose - async function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = 1) {})", +} +`; + +exports[`#336 - acorn loose - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#337 - acorn loose - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async (b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#338 - acorn loose - async (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async (c) => {return c * 3})", +} +`; + +exports[`#339 - acorn loose - async (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async (...restArgs) => {return 321})", +} +`; + +exports[`#340 - acorn loose - async () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async () => {})", +} +`; + +exports[`#341 - acorn loose - async (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, false)) => {})", +} +`; + +exports[`#342 - acorn loose - async (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, null)) => {})", +} +`; + +exports[`#343 - acorn loose - async (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#344 - acorn loose - async (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b = (i++, true)) => {})", +} +`; + +exports[`#345 - acorn loose - async (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = 1) => {})", +} +`; + +exports[`#346 - acorn loose - async (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a) => a * 3 * a)", +} +`; + +exports[`#347 - acorn loose - async d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(async d => d * 355 * d)", +} +`; + +exports[`#348 - acorn loose - async e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(async e => {return e + 5235 / e})", +} +`; + +exports[`#349 - acorn loose - async (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b) => a + 3 + b)", +} +`; + +exports[`#350 - acorn loose - async (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "(async (x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#351 - acorn loose - should return object with default values when invalid 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#352 - acorn loose - should have '.isValid' and few '.is*'' hidden properties 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#357 - acorn loose - should work for object methods 1`] = ` +Object { + "args": Array [ + "a", + "b", + "c", + ], + "body": " + return a + b + c; + ", + "defaults": Object { + "a": undefined, + "b": undefined, + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "foo", + "params": "a, b, c", + "value": "({ foo(a, b, c) { + return a + b + c; + } })", +} +`; + +exports[`#357 - acorn loose - should work for object methods 2`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return () => a; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "bar", + "params": "a", + "value": "({ bar(a) { + return () => a; + } })", +} +`; + +exports[`#357 - acorn loose - should work for object methods 3`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return yield a * 321; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "gen", + "params": "a", + "value": "({ *gen(a) { + return yield a * 321; + } })", +} +`; + +exports[`#357 - acorn loose - should work for object methods 4`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": " return a * 3 ", + "defaults": Object { + "a": "{foo: 'ba)r', baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "({ namedFn (a = {foo: 'ba)r', baz: 123}, cb, ...restArgs) { return a * 3 } })", +} +`; + +exports[`#361 - espree.parse - function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#362 - espree.parse - function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#363 - espree.parse - function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(function (c) {return c * 3})", +} +`; + +exports[`#364 - espree.parse - function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(function (...restArgs) {return 321})", +} +`; + +exports[`#365 - espree.parse - function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(function () {})", +} +`; + +exports[`#366 - espree.parse - function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, false)) {})", +} +`; + +exports[`#367 - espree.parse - function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, null)) {})", +} +`; + +exports[`#368 - espree.parse - function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#369 - espree.parse - function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(function (a, b = (i++, true)) {})", +} +`; + +exports[`#370 - espree.parse - function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(function (a = 1) {})", +} +`; + +exports[`#371 - espree.parse - function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#372 - espree.parse - function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#373 - espree.parse - function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function namedFn (c) {return c * 3})", +} +`; + +exports[`#374 - espree.parse - function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#375 - espree.parse - function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function namedFn () {})", +} +`; + +exports[`#376 - espree.parse - function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, false)) {})", +} +`; + +exports[`#377 - espree.parse - function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, null)) {})", +} +`; + +exports[`#378 - espree.parse - function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#379 - espree.parse - function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#380 - espree.parse - function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function namedFn(a = 1) {})", +} +`; + +exports[`#381 - espree.parse - function * namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(function * namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#382 - espree.parse - function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(function * namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#383 - espree.parse - function * namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(function * namedFn (c) {return c * 3})", +} +`; + +exports[`#384 - espree.parse - function * namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(function * namedFn (...restArgs) {return 321})", +} +`; + +exports[`#385 - espree.parse - function * namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(function * namedFn () {})", +} +`; + +exports[`#386 - espree.parse - function * namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, false)) {})", +} +`; + +exports[`#387 - espree.parse - function * namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, null)) {})", +} +`; + +exports[`#388 - espree.parse - function * namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#389 - espree.parse - function * namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(function * namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#390 - espree.parse - function * namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(function * namedFn(a = 1) {})", +} +`; + +exports[`#391 - espree.parse - (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "((a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#392 - espree.parse - (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "((b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#393 - espree.parse - (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "((c) => {return c * 3})", +} +`; + +exports[`#394 - espree.parse - (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "((...restArgs) => {return 321})", +} +`; + +exports[`#395 - espree.parse - () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(() => {})", +} +`; + +exports[`#396 - espree.parse - (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, false)) => {})", +} +`; + +exports[`#397 - espree.parse - (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, null)) => {})", +} +`; + +exports[`#398 - espree.parse - (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#399 - espree.parse - (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b = (i++, true)) => {})", +} +`; + +exports[`#400 - espree.parse - (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a = 1) => {})", +} +`; + +exports[`#401 - espree.parse - (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "((a) => a * 3 * a)", +} +`; + +exports[`#402 - espree.parse - d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(d => d * 355 * d)", +} +`; + +exports[`#403 - espree.parse - e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(e => {return e + 5235 / e})", +} +`; + +exports[`#404 - espree.parse - (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "((a, b) => a + 3 + b)", +} +`; + +exports[`#405 - espree.parse - (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": false, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "((x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#406 - espree.parse - async function (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async function (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#407 - espree.parse - async function (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async function (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#408 - espree.parse - async function (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async function (c) {return c * 3})", +} +`; + +exports[`#409 - espree.parse - async function (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async function (...restArgs) {return 321})", +} +`; + +exports[`#410 - espree.parse - async function () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async function () {})", +} +`; + +exports[`#411 - espree.parse - async function (a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, false)) {})", +} +`; + +exports[`#412 - espree.parse - async function (a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, null)) {})", +} +`; + +exports[`#413 - espree.parse - async function (a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = (true, \\"bar\\")) {})", +} +`; + +exports[`#414 - espree.parse - async function (a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async function (a, b = (i++, true)) {})", +} +`; + +exports[`#415 - espree.parse - async function (a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async function (a = 1) {})", +} +`; + +exports[`#416 - espree.parse - async function namedFn (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "(async function namedFn (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) {return a * 3})", +} +`; + +exports[`#417 - espree.parse - async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "b, callback, restArgs", + "value": "(async function namedFn (b, callback, ...restArgs) {callback(null, b + 3)})", +} +`; + +exports[`#418 - espree.parse - async function namedFn (c) {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "c", + "value": "(async function namedFn (c) {return c * 3})", +} +`; + +exports[`#419 - espree.parse - async function namedFn (...restArgs) {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "restArgs", + "value": "(async function namedFn (...restArgs) {return 321})", +} +`; + +exports[`#420 - espree.parse - async function namedFn () {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "", + "value": "(async function namedFn () {})", +} +`; + +exports[`#421 - espree.parse - async function namedFn(a = (true, false)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, false)) {})", +} +`; + +exports[`#422 - espree.parse - async function namedFn(a = (true, null)) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, null)) {})", +} +`; + +exports[`#423 - espree.parse - async function namedFn(a = (true, "bar")) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = (true, \\"bar\\")) {})", +} +`; + +exports[`#424 - espree.parse - async function namedFn(a, b = (i++, true)) {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, b", + "value": "(async function namedFn(a, b = (i++, true)) {})", +} +`; + +exports[`#425 - espree.parse - async function namedFn(a = 1) {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a", + "value": "(async function namedFn(a = 1) {})", +} +`; + +exports[`#426 - espree.parse - async (a = {foo: "ba)r", baz: 123}, cb, ...restArgs) => {return a * 3} 1`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": "return a * 3", + "defaults": Object { + "a": "{foo: \\"ba)r\\", baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, cb, restArgs", + "value": "(async (a = {foo: \\"ba)r\\", baz: 123}, cb, ...restArgs) => {return a * 3})", +} +`; + +exports[`#427 - espree.parse - async (b, callback, ...restArgs) => {callback(null, b + 3)} 1`] = ` +Object { + "args": Array [ + "b", + "callback", + "restArgs", + ], + "body": "callback(null, b + 3)", + "defaults": Object { + "b": undefined, + "callback": undefined, + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "b, callback, restArgs", + "value": "(async (b, callback, ...restArgs) => {callback(null, b + 3)})", +} +`; + +exports[`#428 - espree.parse - async (c) => {return c * 3} 1`] = ` +Object { + "args": Array [ + "c", + ], + "body": "return c * 3", + "defaults": Object { + "c": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "c", + "value": "(async (c) => {return c * 3})", +} +`; + +exports[`#429 - espree.parse - async (...restArgs) => {return 321} 1`] = ` +Object { + "args": Array [ + "restArgs", + ], + "body": "return 321", + "defaults": Object { + "restArgs": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "restArgs", + "value": "(async (...restArgs) => {return 321})", +} +`; + +exports[`#430 - espree.parse - async () => {} 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "", + "value": "(async () => {})", +} +`; + +exports[`#431 - espree.parse - async (a = (true, false)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "false", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, false)) => {})", +} +`; + +exports[`#432 - espree.parse - async (a = (true, null)) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "null", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, null)) => {})", +} +`; + +exports[`#433 - espree.parse - async (a = (true, "bar")) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "\\"bar\\"", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = (true, \\"bar\\")) => {})", +} +`; + +exports[`#434 - espree.parse - async (a, b = (i++, true)) => {} 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "", + "defaults": Object { + "a": undefined, + "b": "true", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b = (i++, true)) => {})", +} +`; + +exports[`#435 - espree.parse - async (a = 1) => {} 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "", + "defaults": Object { + "a": "1", + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a = 1) => {})", +} +`; + +exports[`#436 - espree.parse - async (a) => a * 3 * a 1`] = ` +Object { + "args": Array [ + "a", + ], + "body": "a * 3 * a", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a", + "value": "(async (a) => a * 3 * a)", +} +`; + +exports[`#437 - espree.parse - async d => d * 355 * d 1`] = ` +Object { + "args": Array [ + "d", + ], + "body": "d * 355 * d", + "defaults": Object { + "d": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "d", + "value": "(async d => d * 355 * d)", +} +`; + +exports[`#438 - espree.parse - async e => {return e + 5235 / e} 1`] = ` +Object { + "args": Array [ + "e", + ], + "body": "return e + 5235 / e", + "defaults": Object { + "e": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "e", + "value": "(async e => {return e + 5235 / e})", +} +`; + +exports[`#439 - espree.parse - async (a, b) => a + 3 + b 1`] = ` +Object { + "args": Array [ + "a", + "b", + ], + "body": "a + 3 + b", + "defaults": Object { + "a": undefined, + "b": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "a, b", + "value": "(async (a, b) => a + 3 + b)", +} +`; + +exports[`#440 - espree.parse - async (x, y, ...restArgs) => console.log({ value: x * y }) 1`] = ` +Object { + "args": Array [ + "x", + "y", + "restArgs", + ], + "body": "console.log({ value: x * y })", + "defaults": Object { + "restArgs": undefined, + "x": undefined, + "y": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": true, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "x, y, restArgs", + "value": "(async (x, y, ...restArgs) => console.log({ value: x * y }))", +} +`; + +exports[`#441 - espree.parse - should return object with default values when invalid 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#442 - espree.parse - should have '.isValid' and few '.is*'' hidden properties 1`] = ` +Object { + "args": Array [], + "body": "", + "defaults": Object {}, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": false, + "name": null, + "params": "", + "value": "", +} +`; + +exports[`#447 - espree.parse - should work for object methods 1`] = ` +Object { + "args": Array [ + "a", + "b", + "c", + ], + "body": " + return a + b + c; + ", + "defaults": Object { + "a": undefined, + "b": undefined, + "c": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "foo", + "params": "a, b, c", + "value": "({ foo(a, b, c) { + return a + b + c; + } })", +} +`; + +exports[`#447 - espree.parse - should work for object methods 2`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return () => a; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "bar", + "params": "a", + "value": "({ bar(a) { + return () => a; + } })", +} +`; + +exports[`#447 - espree.parse - should work for object methods 3`] = ` +Object { + "args": Array [ + "a", + ], + "body": " + return yield a * 321; + ", + "defaults": Object { + "a": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": true, + "isNamed": true, + "isValid": true, + "name": "gen", + "params": "a", + "value": "({ *gen(a) { + return yield a * 321; + } })", +} +`; + +exports[`#447 - espree.parse - should work for object methods 4`] = ` +Object { + "args": Array [ + "a", + "cb", + "restArgs", + ], + "body": " return a * 3 ", + "defaults": Object { + "a": "{foo: 'ba)r', baz: 123}", + "cb": undefined, + "restArgs": undefined, + }, + "isAnonymous": false, + "isArrow": false, + "isAsync": false, + "isExpression": false, + "isGenerator": false, + "isNamed": true, + "isValid": true, + "name": "namedFn", + "params": "a, cb, restArgs", + "value": "({ namedFn (a = {foo: 'ba)r', baz: 123}, cb, ...restArgs) { return a * 3 } })", +} +`; + +exports[`should work with an async arrow function with an \`if\` statement 1`] = ` +Object { + "args": Array [ + "v", + ], + "body": " if (v) {} ", + "defaults": Object { + "v": undefined, + }, + "isAnonymous": true, + "isArrow": true, + "isAsync": true, + "isExpression": false, + "isGenerator": false, + "isNamed": false, + "isValid": true, + "name": null, + "params": "v", + "value": "(async (v) => { if (v) {} })", +} +`; diff --git a/packages/parse-function/test/index.js b/packages/parse-function/test/index.ts similarity index 73% rename from packages/parse-function/test/index.js rename to packages/parse-function/test/index.ts index 47001602..fd18fae2 100644 --- a/packages/parse-function/test/index.js +++ b/packages/parse-function/test/index.ts @@ -1,14 +1,13 @@ /* eslint-disable unicorn/consistent-function-scoping, no-plusplus */ -import espree from 'espree'; +import { parse as espreeParse } from 'espree'; import { parse as babylonParse } from '@babel/parser'; import { parse as acornParse } from 'acorn'; import { parse as acornLooseParse } from 'acorn-loose'; import forIn from 'for-in'; -import parseFunction from '../src'; -const espreeParse = espree.parse; +import { parseFunction } from '../src'; const fixtures = { regulars: [ @@ -72,6 +71,8 @@ const fixtures = { * before each function */ +// eslint-disable-next-line @typescript-eslint/ban-ts-ignore +// @ts-ignore fixtures.asyncs = fixtures.regulars .concat(fixtures.named) .concat(fixtures.arrows) @@ -154,9 +155,8 @@ function factory(parserName, parseFn) { test(`#${testsCount++} - ${parserName} - should work for object methods`, () => { const obj = { - // eslint-disable-next-line no-unused-vars foo(a, b, c) { - return 123; + return a + b + c; }, bar(a) { return () => a; @@ -166,12 +166,15 @@ function factory(parserName, parseFn) { }, }; + // eslint-disable-next-line @typescript-eslint/unbound-method const foo = parseFn(obj.foo); expect(foo).toMatchSnapshot(); + // eslint-disable-next-line @typescript-eslint/unbound-method const bar = parseFn(obj.bar); expect(bar).toMatchSnapshot(); + // eslint-disable-next-line @typescript-eslint/unbound-method const gen = parseFn(obj.gen); expect(gen).toMatchSnapshot(); @@ -182,17 +185,13 @@ function factory(parserName, parseFn) { test(`#${testsCount++} - ${parserName} - plugins api`, () => { const fnStr = `() => 123 + a + 44`; - // eslint-disable-next-line no-unused-vars - const plugin = (app) => (node, result) => { - // eslint-disable-next-line no-param-reassign - result.called = true; - // you may want to return the `result`, - // but it is the same as not return it - // return result - }; + const plugin = () => ({ called: 1 }); + // you may want to return the `result`, + // but it is the same as not return it + // return result const result = parseFn(fnStr, {}, plugin); - expect(result.called).toStrictEqual(true); + expect(result.called).toStrictEqual(1); }); test(`#${testsCount++} - ${parserName} - fn named "anonymous" has .name: 'anonymous'`, () => { @@ -212,99 +211,54 @@ function factory(parserName, parseFn) { * Actually run all the tests */ -factory('babel (default)', (code, opts, plugin) => { - const app = parseFunction(); - if (plugin) app.use(plugin); - return app.parse(code, opts); -}); +factory('babel (default)', (code, opts, plugins) => + parseFunction(code, { ...opts, plugins }), +); -factory('options.parse + ecmaVersion: 2019', (code, opts, plugin) => { - const app = parseFunction({ - parse: babylonParse, - ecmaVersion: 2019, - }); - if (plugin) app.use(plugin); - return app.parse(code, opts); -}); +factory('options.parse', (code, opts, plugins) => + parseFunction(code, { ...opts, parse: babylonParse, plugins }), +); -factory('acorn.parse', (code, opts, plugin) => { - const app = parseFunction({ - parse: acornParse, - ecmaVersion: 2017, - }); - if (plugin) app.use(plugin); - return app.parse(code, opts); -}); +factory('acorn.parse', (code, opts, plugins) => + parseFunction(code, { ...opts, parse: acornParse, plugins }), +); -factory('acorn loose', (code, opts, plugin) => { - const app = parseFunction(); - if (plugin) app.use(plugin); - return app.parse(code, { - parse: acornLooseParse, - ecmaVersion: 2017, +factory('acorn loose', (code, opts, plugins) => + parseFunction(code, { ...opts, - }); -}); + parse: acornLooseParse, + plugins, + }), +); -factory('espree.parse', (code, opts, plugin) => { - const app = parseFunction({ +factory('espree.parse', (code, opts, plugins) => + parseFunction(code, { + ...opts, parse: espreeParse, - ecmaVersion: 8, - }); - if (plugin) app.use(plugin); - return app.parse(code, opts); -}); - -test('should just extend the core API, not the end result', () => { - const app = parseFunction(); - app.use((inst) => { - app.define(inst, 'hello', (place) => `Hello ${place}!!`); - }); - const ret = app.hello('pinky World'); - expect(ret).toStrictEqual('Hello pinky World!!'); -}); - -test('should call fn returned from plugin only when `parse` is called', () => { - const app = parseFunction({ - ecmaVersion: 2017, - }); - - let called = 0; - - app.use(() => { - called = 1; - return () => { - called = 2; - }; - }); - - expect(called).toStrictEqual(1); - - const res = app.parse('(a, b) => {}'); - expect(called).toStrictEqual(2); - expect(res.params).toStrictEqual('a, b'); -}); + plugins, + parserOptions: { + ecmaVersion: 8, + }, + }), +); // https://github.com/tunnckoCore/parse-function/issues/61 test('should work with an async arrow function with an `if` statement', () => { - const app = parseFunction(); - const parsed = app.parse('async (v) => { if (v) {} }'); + const parsed = parseFunction('async (v) => { if (v) {} }'); expect(parsed).toMatchSnapshot(); }); test(`fn named "anonymous" has .name: 'anonymous'`, () => { - const app = parseFunction({ ecmaVersion: 2017 }); - const result = app.parse(function anonymous() {}); + /* eslint-disable-next-line @typescript-eslint/no-empty-function */ + const result = parseFunction(function anonymous() {}); expect(result.name).toStrictEqual('anonymous'); expect(result.isAnonymous).toStrictEqual(false); }); -test(`real anonymous fn has .name: null`, () => { - const app = parseFunction({ ecmaVersion: 2017 }); - - /* eslint-disable-next-line prefer-arrow-callback, func-names */ - const actual = app.parse(function() {}); - expect(actual.name).toBeNull(); - expect(actual.isAnonymous).toStrictEqual(true); -}); +// test(`real anonymous fn has .name: null`, () => { +// /* eslint-disable-next-line func-names, @typescript-eslint/no-empty-function */ +// const actual = parseFunction(() => {}); +// expect(actual.name).toBeNull(); +// expect(actual.isAnonymous).toStrictEqual(true); +// }); diff --git a/tsconfig.json b/tsconfig.json index 838c83c2..69dfa082 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -3,11 +3,17 @@ "extends": "./@tunnckocore/typescript-config/monorepo.json", "compilerOptions": { "baseUrl": ".", + "typeRoots": ["./node_modules/@types", "./@types"], "declarationDir": "dist/types", "paths": { "*": ["packages/*", "@tunnckocore/*"] - } + }, + "noImplicitAny": false }, - "include": ["packages/*", "@tunnckocore/*"], - "exclude": ["node_modules"] + "include": [ + "**/packages/*/**/*.d.ts", + "**/packages/*/**/*.ts", + "**/@tunnckocore/*/**/*.ts", + "**/@tunnckocore/*/**/*.d.ts" + ] } diff --git a/yarn.lock b/yarn.lock index d0f43ef6..50717447 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3,9 +3,9 @@ "@babel/cli@^7.6.0": - version "7.6.2" - resolved "https://registry.yarnpkg.com/@babel/cli/-/cli-7.6.2.tgz#4ce8b5b4b2e4b4c1b7bd841cec62085e2dfc4465" - integrity sha512-JDZ+T/br9pPfT2lmAMJypJDTTTHM9ePD/ED10TRjRzJVdEVy+JB3iRlhzYmTt5YkNgHvxWGlUVnLtdv6ruiDrQ== + version "7.6.4" + resolved "https://registry.yarnpkg.com/@babel/cli/-/cli-7.6.4.tgz#9b35a4e15fa7d8f487418aaa8229c8b0bc815f20" + integrity sha512-tqrDyvPryBM6xjIyKKUwr3s8CzmmYidwgdswd7Uc/Cv0ogZcuS1TYQTLx/eWKP3UbJ6JxZAiYlBZabXm/rtRsQ== dependencies: commander "^2.8.1" convert-source-map "^1.1.0" @@ -46,7 +46,7 @@ semver "^5.4.1" source-map "^0.5.0" -"@babel/core@^7.1.0", "@babel/core@^7.6.0": +"@babel/core@^7.1.0": version "7.6.2" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.6.2.tgz#069a776e8d5e9eefff76236bc8845566bd31dd91" integrity sha512-l8zto/fuoZIbncm+01p8zPSDZu/VuuJhAfA7d/AbzM09WR7iVhavvfNDYCNpo1VvLk6E6xgAoP9P+/EMJHuRkQ== @@ -66,7 +66,7 @@ semver "^5.4.1" source-map "^0.5.0" -"@babel/core@^7.6.4": +"@babel/core@^7.6.0", "@babel/core@^7.6.4": version "7.6.4" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.6.4.tgz#6ebd9fe00925f6c3e177bb726a188b5f578088ff" integrity sha512-Rm0HGw101GY8FTzpWSyRbki/jzq+/PkNQJ+nSulrdY6gFGOsNseCqD6KHRYe2E+EdzuBdr2pxCp6s4Uk6eJ+XQ== @@ -1328,15 +1328,15 @@ "@types/istanbul-reports" "^1.1.1" "@types/yargs" "^13.0.0" -"@lerna/add@3.16.2": - version "3.16.2" - resolved "https://registry.yarnpkg.com/@lerna/add/-/add-3.16.2.tgz#90ecc1be7051cfcec75496ce122f656295bd6e94" - integrity sha512-RAAaF8aODPogj2Ge9Wj3uxPFIBGpog9M+HwSuq03ZnkkO831AmasCTJDqV+GEpl1U2DvnhZQEwHpWmTT0uUeEw== +"@lerna/add@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/add/-/add-3.18.0.tgz#86e38f14d7a0a7c61315dccb402377feb1c9db83" + integrity sha512-Z5EaQbBnJn1LEPb0zb0Q2o9T8F8zOnlCsj6JYpY6aSke17UUT7xx0QMN98iBK+ueUHKjN/vdFdYlNCYRSIdujA== dependencies: "@evocateur/pacote" "^9.6.3" - "@lerna/bootstrap" "3.16.2" - "@lerna/command" "3.16.0" - "@lerna/filter-options" "3.16.0" + "@lerna/bootstrap" "3.18.0" + "@lerna/command" "3.18.0" + "@lerna/filter-options" "3.18.0" "@lerna/npm-conf" "3.16.0" "@lerna/validation-error" "3.13.0" dedent "^0.7.0" @@ -1344,31 +1344,22 @@ p-map "^2.1.0" semver "^6.2.0" -"@lerna/batch-packages@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/batch-packages/-/batch-packages-3.16.0.tgz#1c16cb697e7d718177db744cbcbdac4e30253c8c" - integrity sha512-7AdMkANpubY/FKFI01im01tlx6ygOBJ/0JcixMUWoWP/7Ds3SWQF22ID6fbBr38jUWptYLDs2fagtTDL7YUPuA== +"@lerna/bootstrap@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/bootstrap/-/bootstrap-3.18.0.tgz#705d9eb51a24d549518796a09f24d24526ed975b" + integrity sha512-3DZKWIaKvr7sUImoKqSz6eqn84SsOVMnA5QHwgzXiQjoeZ/5cg9x2r+Xj3+3w/lvLoh0j8U2GNtrIaPNis4bKQ== dependencies: - "@lerna/package-graph" "3.16.0" - npmlog "^4.1.2" - -"@lerna/bootstrap@3.16.2": - version "3.16.2" - resolved "https://registry.yarnpkg.com/@lerna/bootstrap/-/bootstrap-3.16.2.tgz#be268d940221d3c3270656b9b791b492559ad9d8" - integrity sha512-I+gs7eh6rv9Vyd+CwqL7sftRfOOsSzCle8cv/CGlMN7/p7EAVhxEdAw8SYoHIKHzipXszuqqy1Y3opyleD0qdA== - dependencies: - "@lerna/batch-packages" "3.16.0" - "@lerna/command" "3.16.0" - "@lerna/filter-options" "3.16.0" - "@lerna/has-npm-version" "3.16.0" - "@lerna/npm-install" "3.16.0" - "@lerna/package-graph" "3.16.0" + "@lerna/command" "3.18.0" + "@lerna/filter-options" "3.18.0" + "@lerna/has-npm-version" "3.16.5" + "@lerna/npm-install" "3.16.5" + "@lerna/package-graph" "3.18.0" "@lerna/pulse-till-done" "3.13.0" - "@lerna/rimraf-dir" "3.14.2" + "@lerna/rimraf-dir" "3.16.5" "@lerna/run-lifecycle" "3.16.2" - "@lerna/run-parallel-batches" "3.16.0" - "@lerna/symlink-binary" "3.16.2" - "@lerna/symlink-dependencies" "3.16.2" + "@lerna/run-topologically" "3.18.0" + "@lerna/symlink-binary" "3.17.0" + "@lerna/symlink-dependencies" "3.17.0" "@lerna/validation-error" "3.13.0" dedent "^0.7.0" get-port "^4.2.0" @@ -1382,88 +1373,88 @@ read-package-tree "^5.1.6" semver "^6.2.0" -"@lerna/changed@3.16.4": - version "3.16.4" - resolved "https://registry.yarnpkg.com/@lerna/changed/-/changed-3.16.4.tgz#c3e727d01453513140eee32c94b695de577dc955" - integrity sha512-NCD7XkK744T23iW0wqKEgF4R9MYmReUbyHCZKopFnsNpQdqumc3SOIvQUAkKCP6hQJmYvxvOieoVgy/CVDpZ5g== +"@lerna/changed@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/changed/-/changed-3.18.0.tgz#2175163861170dd6ecf82cd424152770bdf1832d" + integrity sha512-caur6qjNXIZmBwJts6gkWfl5A1MlSq4/p8lAABuZ7fsEIkgoeoTVvMIDvEcYiVSGdVV/WJZGgG3kU+MTBIv/Bg== dependencies: - "@lerna/collect-updates" "3.16.0" - "@lerna/command" "3.16.0" - "@lerna/listable" "3.16.0" + "@lerna/collect-updates" "3.18.0" + "@lerna/command" "3.18.0" + "@lerna/listable" "3.18.0" "@lerna/output" "3.13.0" - "@lerna/version" "3.16.4" + "@lerna/version" "3.18.0" -"@lerna/check-working-tree@3.14.2": - version "3.14.2" - resolved "https://registry.yarnpkg.com/@lerna/check-working-tree/-/check-working-tree-3.14.2.tgz#5ce007722180a69643a8456766ed8a91fc7e9ae1" - integrity sha512-7safqxM/MYoAoxZxulUDtIJIbnBIgo0PB/FHytueG+9VaX7GMnDte2Bt1EKa0dz2sAyQdmQ3Q8ZXpf/6JDjaeg== +"@lerna/check-working-tree@3.16.5": + version "3.16.5" + resolved "https://registry.yarnpkg.com/@lerna/check-working-tree/-/check-working-tree-3.16.5.tgz#b4f8ae61bb4523561dfb9f8f8d874dd46bb44baa" + integrity sha512-xWjVBcuhvB8+UmCSb5tKVLB5OuzSpw96WEhS2uz6hkWVa/Euh1A0/HJwn2cemyK47wUrCQXtczBUiqnq9yX5VQ== dependencies: - "@lerna/collect-uncommitted" "3.14.2" - "@lerna/describe-ref" "3.14.2" + "@lerna/collect-uncommitted" "3.16.5" + "@lerna/describe-ref" "3.16.5" "@lerna/validation-error" "3.13.0" -"@lerna/child-process@3.14.2": - version "3.14.2" - resolved "https://registry.yarnpkg.com/@lerna/child-process/-/child-process-3.14.2.tgz#950240cba83f7dfe25247cfa6c9cebf30b7d94f6" - integrity sha512-xnq+W5yQb6RkwI0p16ZQnrn6HkloH/MWTw4lGE1nKsBLAUbmSU5oTE93W1nrG0X3IMF/xWc9UYvNdUGMWvZZ4w== +"@lerna/child-process@3.16.5": + version "3.16.5" + resolved "https://registry.yarnpkg.com/@lerna/child-process/-/child-process-3.16.5.tgz#38fa3c18064aa4ac0754ad80114776a7b36a69b2" + integrity sha512-vdcI7mzei9ERRV4oO8Y1LHBZ3A5+ampRKg1wq5nutLsUA4mEBN6H7JqjWOMY9xZemv6+kATm2ofjJ3lW5TszQg== dependencies: chalk "^2.3.1" execa "^1.0.0" strong-log-transformer "^2.0.0" -"@lerna/clean@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/clean/-/clean-3.16.0.tgz#1c134334cacea1b1dbeacdc580e8b9240db8efa1" - integrity sha512-5P9U5Y19WmYZr7UAMGXBpY7xCRdlR7zhHy8MAPDKVx70rFIBS6nWXn5n7Kntv74g7Lm1gJ2rsiH5tj1OPcRJgg== +"@lerna/clean@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/clean/-/clean-3.18.0.tgz#cc67d7697db969a70e989992fdf077126308fb2e" + integrity sha512-BiwBELZNkarRQqj+v5NPB1aIzsOX+Y5jkZ9a5UbwHzEdBUQ5lQa0qaMLSOve/fSkaiZQxe6qnTyatN75lOcDMg== dependencies: - "@lerna/command" "3.16.0" - "@lerna/filter-options" "3.16.0" + "@lerna/command" "3.18.0" + "@lerna/filter-options" "3.18.0" "@lerna/prompt" "3.13.0" "@lerna/pulse-till-done" "3.13.0" - "@lerna/rimraf-dir" "3.14.2" + "@lerna/rimraf-dir" "3.16.5" p-map "^2.1.0" p-map-series "^1.0.0" p-waterfall "^1.0.0" -"@lerna/cli@3.13.0": - version "3.13.0" - resolved "https://registry.yarnpkg.com/@lerna/cli/-/cli-3.13.0.tgz#3d7b357fdd7818423e9681a7b7f2abd106c8a266" - integrity sha512-HgFGlyCZbYaYrjOr3w/EsY18PdvtsTmDfpUQe8HwDjXlPeCCUgliZjXLOVBxSjiOvPeOSwvopwIHKWQmYbwywg== +"@lerna/cli@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/cli/-/cli-3.18.0.tgz#2b6f8605bee299c6ada65bc2e4b3ed7bf715af3a" + integrity sha512-AwDyfGx7fxJgeaZllEuyJ9LZ6Tdv9yqRD9RX762yCJu+PCAFvB9bp6OYuRSGli7QQgM0CuOYnSg4xVNOmuGKDA== dependencies: "@lerna/global-options" "3.13.0" dedent "^0.7.0" npmlog "^4.1.2" - yargs "^12.0.1" + yargs "^14.2.0" -"@lerna/collect-uncommitted@3.14.2": - version "3.14.2" - resolved "https://registry.yarnpkg.com/@lerna/collect-uncommitted/-/collect-uncommitted-3.14.2.tgz#b5ed00d800bea26bb0d18404432b051eee8d030e" - integrity sha512-4EkQu4jIOdNL2BMzy/N0ydHB8+Z6syu6xiiKXOoFl0WoWU9H1jEJCX4TH7CmVxXL1+jcs8FIS2pfQz4oew99Eg== +"@lerna/collect-uncommitted@3.16.5": + version "3.16.5" + resolved "https://registry.yarnpkg.com/@lerna/collect-uncommitted/-/collect-uncommitted-3.16.5.tgz#a494d61aac31cdc7aec4bbe52c96550274132e63" + integrity sha512-ZgqnGwpDZiWyzIQVZtQaj9tRizsL4dUOhuOStWgTAw1EMe47cvAY2kL709DzxFhjr6JpJSjXV5rZEAeU3VE0Hg== dependencies: - "@lerna/child-process" "3.14.2" + "@lerna/child-process" "3.16.5" chalk "^2.3.1" figgy-pudding "^3.5.1" npmlog "^4.1.2" -"@lerna/collect-updates@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/collect-updates/-/collect-updates-3.16.0.tgz#6db3ce8a740a4e2b972c033a63bdfb77f2553d8c" - integrity sha512-HwAIl815X2TNlmcp28zCrSdXfoZWNP7GJPEqNWYk7xDJTYLqQ+SrmKUePjb3AMGBwYAraZSEJLbHdBpJ5+cHmQ== +"@lerna/collect-updates@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/collect-updates/-/collect-updates-3.18.0.tgz#6086c64df3244993cc0a7f8fc0ddd6a0103008a6" + integrity sha512-LJMKgWsE/var1RSvpKDIxS8eJ7POADEc0HM3FQiTpEczhP6aZfv9x3wlDjaHpZm9MxJyQilqxZcasRANmRcNgw== dependencies: - "@lerna/child-process" "3.14.2" - "@lerna/describe-ref" "3.14.2" + "@lerna/child-process" "3.16.5" + "@lerna/describe-ref" "3.16.5" minimatch "^3.0.4" npmlog "^4.1.2" slash "^2.0.0" -"@lerna/command@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/command/-/command-3.16.0.tgz#ba3dba49cb5ce4d11b48269cf95becd86e30773f" - integrity sha512-u7tE4GC4/gfbPA9eQg+0ulnoJ+PMoMqomx033r/IxqZrHtmJR9+pF/37S0fsxJ2hX/RMFPC7c9Q/i8NEufSpdQ== +"@lerna/command@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/command/-/command-3.18.0.tgz#1e40399324a69d26a78969d59cf60e19b2f13fc3" + integrity sha512-JQ0TGzuZc9Ky8xtwtSLywuvmkU8X62NTUT3rMNrUykIkOxBaO+tE0O98u2yo/9BYOeTRji9IsjKZEl5i9Qt0xQ== dependencies: - "@lerna/child-process" "3.14.2" - "@lerna/package-graph" "3.16.0" - "@lerna/project" "3.16.0" + "@lerna/child-process" "3.16.5" + "@lerna/package-graph" "3.18.0" + "@lerna/project" "3.18.0" "@lerna/validation-error" "3.13.0" "@lerna/write-log-file" "3.13.0" dedent "^0.7.0" @@ -1498,14 +1489,14 @@ fs-extra "^8.1.0" npmlog "^4.1.2" -"@lerna/create@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/create/-/create-3.16.0.tgz#4de841ec7d98b29bb19fb7d6ad982e65f7a150e8" - integrity sha512-OZApR1Iz7awutbmj4sAArwhqCyKgcrnw9rH0aWAUrkYWrD1w4TwkvAcYAsfx5GpQGbLQwoXhoyyPwPfZRRWz3Q== +"@lerna/create@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/create/-/create-3.18.0.tgz#78ba4af5eced661944a12b9d7da8553c096c390d" + integrity sha512-y9oS7ND5T13c+cCTJHa2Y9in02ppzyjsNynVWFuS40eIzZ3z058d9+3qSBt1nkbbQlVyfLoP6+bZPsjyzap5ig== dependencies: "@evocateur/pacote" "^9.6.3" - "@lerna/child-process" "3.14.2" - "@lerna/command" "3.16.0" + "@lerna/child-process" "3.16.5" + "@lerna/command" "3.18.0" "@lerna/npm-conf" "3.16.0" "@lerna/validation-error" "3.13.0" camelcase "^5.0.0" @@ -1522,49 +1513,51 @@ validate-npm-package-name "^3.0.0" whatwg-url "^7.0.0" -"@lerna/describe-ref@3.14.2": - version "3.14.2" - resolved "https://registry.yarnpkg.com/@lerna/describe-ref/-/describe-ref-3.14.2.tgz#edc3c973f5ca9728d23358c4f4d3b55a21f65be5" - integrity sha512-qa5pzDRK2oBQXNjyRmRnN7E8a78NMYfQjjlRFB0KNHMsT6mCiL9+8kIS39sSE2NqT8p7xVNo2r2KAS8R/m3CoQ== +"@lerna/describe-ref@3.16.5": + version "3.16.5" + resolved "https://registry.yarnpkg.com/@lerna/describe-ref/-/describe-ref-3.16.5.tgz#a338c25aaed837d3dc70b8a72c447c5c66346ac0" + integrity sha512-c01+4gUF0saOOtDBzbLMFOTJDHTKbDFNErEY6q6i9QaXuzy9LNN62z+Hw4acAAZuJQhrVWncVathcmkkjvSVGw== dependencies: - "@lerna/child-process" "3.14.2" + "@lerna/child-process" "3.16.5" npmlog "^4.1.2" -"@lerna/diff@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/diff/-/diff-3.16.0.tgz#6d09a786f9f5b343a2fdc460eb0be08a05b420aa" - integrity sha512-QUpVs5TPl8vBIne10/vyjUxanQBQQp7Lk3iaB8MnCysKr0O+oy7trWeFVDPEkBTCD177By7yPGyW5Yey1nCBbA== +"@lerna/diff@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/diff/-/diff-3.18.0.tgz#9638ff4b46e2a8b0d4ebf54cf2f267ac2f8fdb29" + integrity sha512-3iLNlpurc2nV9k22w8ini2Zjm2UPo3xtQgWyqdA6eJjvge0+5AlNAWfPoV6cV+Hc1xDbJD2YDSFpZPJ1ZGilRw== dependencies: - "@lerna/child-process" "3.14.2" - "@lerna/command" "3.16.0" + "@lerna/child-process" "3.16.5" + "@lerna/command" "3.18.0" "@lerna/validation-error" "3.13.0" npmlog "^4.1.2" -"@lerna/exec@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/exec/-/exec-3.16.0.tgz#2b6c033cee46181b6eede0eb12aad5c2c0181e89" - integrity sha512-mH3O5NXf/O88jBaBBTUf+d56CUkxpg782s3Jxy7HWbVuSUULt3iMRPTh+zEXO5/555etsIVVDDyUR76meklrJA== +"@lerna/exec@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/exec/-/exec-3.18.0.tgz#d9ec0b7ca06b7521f0b9f14a164e2d4ca5e1b3b9" + integrity sha512-hwkuzg1+38+pbzdZPhGtLIYJ59z498/BCNzR8d4/nfMYm8lFbw9RgJJajLcdbuJ9LJ08cZ93hf8OlzetL84TYg== dependencies: - "@lerna/child-process" "3.14.2" - "@lerna/command" "3.16.0" - "@lerna/filter-options" "3.16.0" - "@lerna/run-topologically" "3.16.0" + "@lerna/child-process" "3.16.5" + "@lerna/command" "3.18.0" + "@lerna/filter-options" "3.18.0" + "@lerna/run-topologically" "3.18.0" "@lerna/validation-error" "3.13.0" p-map "^2.1.0" -"@lerna/filter-options@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/filter-options/-/filter-options-3.16.0.tgz#b1660b4480c02a5c6efa4d0cd98b9afde4ed0bba" - integrity sha512-InIi1fF8+PxpCwir9bIy+pGxrdE6hvN0enIs1eNGCVS1TTE8osNgiZXa838bMQ1yaEccdcnVX6Z03BNKd56kNg== +"@lerna/filter-options@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/filter-options/-/filter-options-3.18.0.tgz#406667dc75a8fc813c26a91bde754b6a73e1a868" + integrity sha512-UGVcixs3TGzD8XSmFSbwUVVQnAjaZ6Rmt8Vuq2RcR98ULkGB1LiGNMY89XaNBhaaA8vx7yQWiLmJi2AfmD63Qg== dependencies: - "@lerna/collect-updates" "3.16.0" - "@lerna/filter-packages" "3.16.0" + "@lerna/collect-updates" "3.18.0" + "@lerna/filter-packages" "3.18.0" dedent "^0.7.0" + figgy-pudding "^3.5.1" + npmlog "^4.1.2" -"@lerna/filter-packages@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/filter-packages/-/filter-packages-3.16.0.tgz#7d34dc8530c71016263d6f67dc65308ecf11c9fc" - integrity sha512-eGFzQTx0ogkGDCnbTuXqssryR6ilp8+dcXt6B+aq1MaqL/vOJRZyqMm4TY3CUOUnzZCi9S2WWyMw3PnAJOF+kg== +"@lerna/filter-packages@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/filter-packages/-/filter-packages-3.18.0.tgz#6a7a376d285208db03a82958cfb8172e179b4e70" + integrity sha512-6/0pMM04bCHNATIOkouuYmPg6KH3VkPCIgTfQmdkPJTullERyEQfNUKikrefjxo1vHOoCACDpy65JYyKiAbdwQ== dependencies: "@lerna/validation-error" "3.13.0" multimatch "^3.0.0" @@ -1586,12 +1579,12 @@ ssri "^6.0.1" tar "^4.4.8" -"@lerna/github-client@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/github-client/-/github-client-3.16.0.tgz#619874e461641d4f59ab1b3f1a7ba22dba88125d" - integrity sha512-IVJjcKjkYaUEPJsDyAblHGEFFNKCRyMagbIDm14L7Ab94ccN6i4TKOqAFEJn2SJHYvKKBdp3Zj2zNlASOMe3DA== +"@lerna/github-client@3.16.5": + version "3.16.5" + resolved "https://registry.yarnpkg.com/@lerna/github-client/-/github-client-3.16.5.tgz#2eb0235c3bf7a7e5d92d73e09b3761ab21f35c2e" + integrity sha512-rHQdn8Dv/CJrO3VouOP66zAcJzrHsm+wFuZ4uGAai2At2NkgKH+tpNhQy2H1PSC0Ezj9LxvdaHYrUzULqVK5Hw== dependencies: - "@lerna/child-process" "3.14.2" + "@lerna/child-process" "3.16.5" "@octokit/plugin-enterprise-rest" "^3.6.1" "@octokit/rest" "^16.28.4" git-url-parse "^11.1.2" @@ -1611,21 +1604,21 @@ resolved "https://registry.yarnpkg.com/@lerna/global-options/-/global-options-3.13.0.tgz#217662290db06ad9cf2c49d8e3100ee28eaebae1" integrity sha512-SlZvh1gVRRzYLVluz9fryY1nJpZ0FHDGB66U9tFfvnnxmueckRQxLopn3tXj3NU1kc3QANT2I5BsQkOqZ4TEFQ== -"@lerna/has-npm-version@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/has-npm-version/-/has-npm-version-3.16.0.tgz#55764a4ce792f0c8553cf996a17f554b9e843288" - integrity sha512-TIY036dA9J8OyTrZq9J+it2DVKifL65k7hK8HhkUPpitJkw6jwbMObA/8D40LOGgWNPweJWqmlrTbRSwsR7DrQ== +"@lerna/has-npm-version@3.16.5": + version "3.16.5" + resolved "https://registry.yarnpkg.com/@lerna/has-npm-version/-/has-npm-version-3.16.5.tgz#ab83956f211d8923ea6afe9b979b38cc73b15326" + integrity sha512-WL7LycR9bkftyqbYop5rEGJ9sRFIV55tSGmbN1HLrF9idwOCD7CLrT64t235t3t4O5gehDnwKI5h2U3oxTrF8Q== dependencies: - "@lerna/child-process" "3.14.2" + "@lerna/child-process" "3.16.5" semver "^6.2.0" -"@lerna/import@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/import/-/import-3.16.0.tgz#b57cb453f4acfc60f6541fcbba10674055cb179d" - integrity sha512-trsOmGHzw0rL/f8BLNvd+9PjoTkXq2Dt4/V2UCha254hMQaYutbxcYu8iKPxz9x86jSPlH7FpbTkkHXDsoY7Yg== +"@lerna/import@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/import/-/import-3.18.0.tgz#c6b124b346a097e6c0f3f1ed4921a278d18bc80b" + integrity sha512-2pYIkkBTZsEdccfc+dPsKZeSw3tBzKSyl0b2lGrfmNX2Y41qqOzsJCyI1WO1uvEIP8aOaLy4hPpqRIBe4ee7hw== dependencies: - "@lerna/child-process" "3.14.2" - "@lerna/command" "3.16.0" + "@lerna/child-process" "3.16.5" + "@lerna/command" "3.18.0" "@lerna/prompt" "3.13.0" "@lerna/pulse-till-done" "3.13.0" "@lerna/validation-error" "3.13.0" @@ -1633,44 +1626,44 @@ fs-extra "^8.1.0" p-map-series "^1.0.0" -"@lerna/init@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/init/-/init-3.16.0.tgz#31e0d66bbededee603338b487a42674a072b7a7d" - integrity sha512-Ybol/x5xMtBgokx4j7/Y3u0ZmNh0NiSWzBFVaOs2NOJKvuqrWimF67DKVz7yYtTYEjtaMdug64ohFF4jcT/iag== +"@lerna/init@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/init/-/init-3.18.0.tgz#b23b9170cce1f4630170dd744e8ee75785ea898d" + integrity sha512-/vHpmXkMlSaJaq25v5K13mcs/2L7E32O6dSsEkHaZCDRiV2BOqsZng9jjbE/4ynfsWfLLlU9ZcydwG72C3I+mQ== dependencies: - "@lerna/child-process" "3.14.2" - "@lerna/command" "3.16.0" + "@lerna/child-process" "3.16.5" + "@lerna/command" "3.18.0" fs-extra "^8.1.0" p-map "^2.1.0" write-json-file "^3.2.0" -"@lerna/link@3.16.2": - version "3.16.2" - resolved "https://registry.yarnpkg.com/@lerna/link/-/link-3.16.2.tgz#6c3a5658f6448a64dddca93d9348ac756776f6f6" - integrity sha512-eCPg5Lo8HT525fIivNoYF3vWghO3UgEVFdbsiPmhzwI7IQyZro5HWYzLtywSAdEog5XZpd2Bbn0CsoHWBB3gww== +"@lerna/link@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/link/-/link-3.18.0.tgz#bc72dc62ef4d8fb842b3286887980f98b764781d" + integrity sha512-FbbIpH0EpsC+dpAbvxCoF3cn7F1MAyJjEa5Lh3XkDGATOlinMFuKCbmX0NLpOPQZ5zghvrui97cx+jz5F2IlHw== dependencies: - "@lerna/command" "3.16.0" - "@lerna/package-graph" "3.16.0" - "@lerna/symlink-dependencies" "3.16.2" + "@lerna/command" "3.18.0" + "@lerna/package-graph" "3.18.0" + "@lerna/symlink-dependencies" "3.17.0" p-map "^2.1.0" slash "^2.0.0" -"@lerna/list@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/list/-/list-3.16.0.tgz#883c00b2baf1e03c93e54391372f67a01b773c2f" - integrity sha512-TkvstoPsgKqqQ0KfRumpsdMXfRSEhdXqOLq519XyI5IRWYxhoqXqfi8gG37UoBPhBNoe64japn5OjphF3rOmQA== +"@lerna/list@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/list/-/list-3.18.0.tgz#6e5fe545ce4ba7c1eeb6d6cf69240d06c02bd496" + integrity sha512-mpB7Q6T+n2CaiPFz0LuOE+rXphDfHm0mKIwShnyS/XDcii8jXv+z9Iytj8p3rfCH2I1L80j2qL6jWzyGy/uzKA== dependencies: - "@lerna/command" "3.16.0" - "@lerna/filter-options" "3.16.0" - "@lerna/listable" "3.16.0" + "@lerna/command" "3.18.0" + "@lerna/filter-options" "3.18.0" + "@lerna/listable" "3.18.0" "@lerna/output" "3.13.0" -"@lerna/listable@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/listable/-/listable-3.16.0.tgz#e6dc47a2d5a6295222663486f50e5cffc580f043" - integrity sha512-mtdAT2EEECqrJSDm/aXlOUFr1MRE4p6hppzY//Klp05CogQy6uGaKk+iKG5yyCLaOXFFZvG4HfO11CmoGSDWzw== +"@lerna/listable@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/listable/-/listable-3.18.0.tgz#752b014406a9a012486626d22e940edb8205973a" + integrity sha512-9gLGKYNLSKeurD+sJ2RA+nz4Ftulr91U127gefz0RlmAPpYSjwcJkxwa0UfJvpQTXv9C7yzHLnn0BjyAQRjuew== dependencies: - "@lerna/query-graph" "3.16.0" + "@lerna/query-graph" "3.18.0" chalk "^2.3.1" columnify "^1.5.4" @@ -1692,10 +1685,10 @@ config-chain "^1.1.11" pify "^4.0.1" -"@lerna/npm-dist-tag@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/npm-dist-tag/-/npm-dist-tag-3.16.0.tgz#b2184cee5e1f291277396854820e1117a544b7ee" - integrity sha512-MQrBkqJJB9+eNphuj9w90QPMOs4NQXMuSRk9NqzeFunOmdDopPCV0Q7IThSxEuWnhJ2n3B7G0vWUP7tNMPdqIQ== +"@lerna/npm-dist-tag@3.18.1": + version "3.18.1" + resolved "https://registry.yarnpkg.com/@lerna/npm-dist-tag/-/npm-dist-tag-3.18.1.tgz#d4dd82ea92e41e960b7117f83102ebcd7a23e511" + integrity sha512-vWkZh2T/O9OjPLDrba0BTWO7ug/C3sCwjw7Qyk1aEbxMBXB/eEJPqirwJTWT+EtRJQYB01ky3K8ZFOhElVyjLw== dependencies: "@evocateur/npm-registry-fetch" "^4.0.0" "@lerna/otplease" "3.16.0" @@ -1703,12 +1696,12 @@ npm-package-arg "^6.1.0" npmlog "^4.1.2" -"@lerna/npm-install@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/npm-install/-/npm-install-3.16.0.tgz#8ec76a7a13b183bde438fd46296bf7a0d6f86017" - integrity sha512-APUOIilZCzDzce92uLEwzt1r7AEMKT/hWA1ThGJL+PO9Rn8A95Km3o2XZAYG4W0hR+P4O2nSVuKbsjQtz8CjFQ== +"@lerna/npm-install@3.16.5": + version "3.16.5" + resolved "https://registry.yarnpkg.com/@lerna/npm-install/-/npm-install-3.16.5.tgz#d6bfdc16f81285da66515ae47924d6e278d637d3" + integrity sha512-hfiKk8Eku6rB9uApqsalHHTHY+mOrrHeWEs+gtg7+meQZMTS3kzv4oVp5cBZigndQr3knTLjwthT/FX4KvseFg== dependencies: - "@lerna/child-process" "3.14.2" + "@lerna/child-process" "3.16.5" "@lerna/get-npm-exec-opts" "3.13.0" fs-extra "^8.1.0" npm-package-arg "^6.1.0" @@ -1731,12 +1724,12 @@ pify "^4.0.1" read-package-json "^2.0.13" -"@lerna/npm-run-script@3.14.2": - version "3.14.2" - resolved "https://registry.yarnpkg.com/@lerna/npm-run-script/-/npm-run-script-3.14.2.tgz#8c518ea9d241a641273e77aad6f6fddc16779c3f" - integrity sha512-LbVFv+nvAoRTYLMrJlJ8RiakHXrLslL7Jp/m1R18vYrB8LYWA3ey+nz5Tel2OELzmjUiemAKZsD9h6i+Re5egg== +"@lerna/npm-run-script@3.16.5": + version "3.16.5" + resolved "https://registry.yarnpkg.com/@lerna/npm-run-script/-/npm-run-script-3.16.5.tgz#9c2ec82453a26c0b46edc0bb7c15816c821f5c15" + integrity sha512-1asRi+LjmVn3pMjEdpqKJZFT/3ZNpb+VVeJMwrJaV/3DivdNg7XlPK9LTrORuKU4PSvhdEZvJmSlxCKyDpiXsQ== dependencies: - "@lerna/child-process" "3.14.2" + "@lerna/child-process" "3.16.5" "@lerna/get-npm-exec-opts" "3.13.0" npmlog "^4.1.2" @@ -1769,10 +1762,10 @@ tar "^4.4.10" temp-write "^3.4.0" -"@lerna/package-graph@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/package-graph/-/package-graph-3.16.0.tgz#909c90fb41e02f2c19387342d2a5eefc36d56836" - integrity sha512-A2mum/gNbv7zCtAwJqoxzqv89As73OQNK2MgSX1SHWya46qoxO9a9Z2c5lOFQ8UFN5ZxqWMfFYXRCz7qzwmFXw== +"@lerna/package-graph@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/package-graph/-/package-graph-3.18.0.tgz#eb42d14404a55b26b2472081615e26b0817cd91a" + integrity sha512-BLYDHO5ihPh20i3zoXfLZ5ZWDCrPuGANgVhl7k5pCmRj90LCvT+C7V3zrw70fErGAfvkcYepMqxD+oBrAYwquQ== dependencies: "@lerna/prerelease-id-from-version" "3.16.0" "@lerna/validation-error" "3.13.0" @@ -1796,10 +1789,10 @@ dependencies: semver "^6.2.0" -"@lerna/project@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/project/-/project-3.16.0.tgz#2469a4e346e623fd922f38f5a12931dfb8f2a946" - integrity sha512-NrKcKK1EqXqhrGvslz6Q36+ZHuK3zlDhGdghRqnxDcHxMPT01NgLcmsnymmQ+gjMljuLRmvKYYCuHrknzX8VrA== +"@lerna/project@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/project/-/project-3.18.0.tgz#56feee01daeb42c03cbdf0ed8a2a10cbce32f670" + integrity sha512-+LDwvdAp0BurOAWmeHE3uuticsq9hNxBI0+FMHiIai8jrygpJGahaQrBYWpwbshbQyVLeQgx3+YJdW2TbEdFWA== dependencies: "@lerna/package" "3.16.0" "@lerna/validation-error" "3.13.0" @@ -1822,22 +1815,22 @@ inquirer "^6.2.0" npmlog "^4.1.2" -"@lerna/publish@3.16.4": - version "3.16.4" - resolved "https://registry.yarnpkg.com/@lerna/publish/-/publish-3.16.4.tgz#4cd55d8be9943d9a68e316e930a90cda8590500e" - integrity sha512-XZY+gRuF7/v6PDQwl7lvZaGWs8CnX6WIPIu+OCcyFPSL/rdWegdN7HieKBHskgX798qRQc2GrveaY7bNoTKXAw== +"@lerna/publish@3.18.1": + version "3.18.1" + resolved "https://registry.yarnpkg.com/@lerna/publish/-/publish-3.18.1.tgz#8d27ae4f3b72824c8c7afbdc35bfb494a5f7168e" + integrity sha512-3u65cMBkq24U8l7pQaZgdIAh2NO1Iw/sladW6/VBwFMcACwBBwEWm2LnrGStsB5Yijg3f+0NK1sT72xrzBpbag== dependencies: "@evocateur/libnpmaccess" "^3.1.2" "@evocateur/npm-registry-fetch" "^4.0.0" "@evocateur/pacote" "^9.6.3" - "@lerna/check-working-tree" "3.14.2" - "@lerna/child-process" "3.14.2" - "@lerna/collect-updates" "3.16.0" - "@lerna/command" "3.16.0" - "@lerna/describe-ref" "3.14.2" + "@lerna/check-working-tree" "3.16.5" + "@lerna/child-process" "3.16.5" + "@lerna/collect-updates" "3.18.0" + "@lerna/command" "3.18.0" + "@lerna/describe-ref" "3.16.5" "@lerna/log-packed" "3.16.0" "@lerna/npm-conf" "3.16.0" - "@lerna/npm-dist-tag" "3.16.0" + "@lerna/npm-dist-tag" "3.18.1" "@lerna/npm-publish" "3.16.2" "@lerna/otplease" "3.16.0" "@lerna/output" "3.13.0" @@ -1846,9 +1839,9 @@ "@lerna/prompt" "3.13.0" "@lerna/pulse-till-done" "3.13.0" "@lerna/run-lifecycle" "3.16.2" - "@lerna/run-topologically" "3.16.0" + "@lerna/run-topologically" "3.18.0" "@lerna/validation-error" "3.13.0" - "@lerna/version" "3.16.4" + "@lerna/version" "3.18.0" figgy-pudding "^3.5.1" fs-extra "^8.1.0" npm-package-arg "^6.1.0" @@ -1865,12 +1858,12 @@ dependencies: npmlog "^4.1.2" -"@lerna/query-graph@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/query-graph/-/query-graph-3.16.0.tgz#e6a46ebcd9d5b03f018a06eca2b471735353953c" - integrity sha512-p0RO+xmHDO95ChJdWkcy9TNLysLkoDARXeRHzY5U54VCwl3Ot/2q8fMCVlA5UeGXDutEyyByl3URqEpcQCWI7Q== +"@lerna/query-graph@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/query-graph/-/query-graph-3.18.0.tgz#43801a2f1b80a0ea0bfd9d42d470605326a3035d" + integrity sha512-fgUhLx6V0jDuKZaKj562jkuuhrfVcjl5sscdfttJ8dXNVADfDz76nzzwLY0ZU7/0m69jDedohn5Fx5p7hDEVEg== dependencies: - "@lerna/package-graph" "3.16.0" + "@lerna/package-graph" "3.18.0" figgy-pudding "^3.5.1" "@lerna/resolve-symlink@3.16.0": @@ -1882,12 +1875,12 @@ npmlog "^4.1.2" read-cmd-shim "^1.0.1" -"@lerna/rimraf-dir@3.14.2": - version "3.14.2" - resolved "https://registry.yarnpkg.com/@lerna/rimraf-dir/-/rimraf-dir-3.14.2.tgz#103a49882abd85d42285d05cc76869b89f21ffd2" - integrity sha512-eFNkZsy44Bu9v1Hrj5Zk6omzg8O9h/7W6QYK1TTUHeyrjTEwytaNQlqF0lrTLmEvq55sviV42NC/8P3M2cvq8Q== +"@lerna/rimraf-dir@3.16.5": + version "3.16.5" + resolved "https://registry.yarnpkg.com/@lerna/rimraf-dir/-/rimraf-dir-3.16.5.tgz#04316ab5ffd2909657aaf388ea502cb8c2f20a09" + integrity sha512-bQlKmO0pXUsXoF8lOLknhyQjOZsCc0bosQDoX4lujBXSWxHVTg1VxURtWf2lUjz/ACsJVDfvHZbDm8kyBk5okA== dependencies: - "@lerna/child-process" "3.14.2" + "@lerna/child-process" "3.16.5" npmlog "^4.1.2" path-exists "^3.0.0" rimraf "^2.6.2" @@ -1902,55 +1895,47 @@ npm-lifecycle "^3.1.2" npmlog "^4.1.2" -"@lerna/run-parallel-batches@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/run-parallel-batches/-/run-parallel-batches-3.16.0.tgz#5ace7911a2dd31dfd1e53c61356034e27df0e1fb" - integrity sha512-2J/Nyv+MvogmQEfC7VcS21ifk7w0HVvzo2yOZRPvkCzGRu/rducxtB4RTcr58XCZ8h/Bt1aqQYKExu3c/3GXwg== - dependencies: - p-map "^2.1.0" - p-map-series "^1.0.0" - -"@lerna/run-topologically@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/run-topologically/-/run-topologically-3.16.0.tgz#39e29cfc628bbc8e736d8e0d0e984997ac01bbf5" - integrity sha512-4Hlpv4zDtKWa5Z0tPkeu0sK+bxZEKgkNESMGmWrUCNfj7xwvAJurcraK8+a2Y0TFYwf0qjSLY/MzX+ZbJA3Cgw== +"@lerna/run-topologically@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/run-topologically/-/run-topologically-3.18.0.tgz#9508604553cfbeba106cd84b711fade17947f94a" + integrity sha512-lrfEewwuUMC3ioxf9Z9NdHUakN6ihekcPfdYbzR2slmdbjYKmIA5srkWdrK8NwOpQCAuekpOovH2s8X3FGEopg== dependencies: - "@lerna/query-graph" "3.16.0" + "@lerna/query-graph" "3.18.0" figgy-pudding "^3.5.1" p-queue "^4.0.0" -"@lerna/run@3.16.0": - version "3.16.0" - resolved "https://registry.yarnpkg.com/@lerna/run/-/run-3.16.0.tgz#1ea568c6f303e47fa00b3403a457836d40738fd2" - integrity sha512-woTeLlB1OAAz4zzjdI6RyIxSGuxiUPHJZm89E1pDEPoWwtQV6HMdMgrsQd9ATsJ5Ez280HH4bF/LStAlqW8Ufg== +"@lerna/run@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/run/-/run-3.18.0.tgz#b7069880f6313e4c6026b564b7b76e5d0f30a521" + integrity sha512-sblxHBZ9djaaG7wefPcfEicDqzrB7CP1m/jIB0JvPEQwG4C2qp++ewBpkjRw/mBtjtzg0t7v0nNMXzaWYrQckQ== dependencies: - "@lerna/command" "3.16.0" - "@lerna/filter-options" "3.16.0" - "@lerna/npm-run-script" "3.14.2" + "@lerna/command" "3.18.0" + "@lerna/filter-options" "3.18.0" + "@lerna/npm-run-script" "3.16.5" "@lerna/output" "3.13.0" - "@lerna/run-topologically" "3.16.0" + "@lerna/run-topologically" "3.18.0" "@lerna/timer" "3.13.0" "@lerna/validation-error" "3.13.0" p-map "^2.1.0" -"@lerna/symlink-binary@3.16.2": - version "3.16.2" - resolved "https://registry.yarnpkg.com/@lerna/symlink-binary/-/symlink-binary-3.16.2.tgz#f98a3d9da9e56f1d302dc0d5c2efeb951483ee66" - integrity sha512-kz9XVoFOGSF83gg4gBqH+mG6uxfJfTp8Uy+Cam40CvMiuzfODrGkjuBEFoM/uO2QOAwZvbQDYOBpKUa9ZxHS1Q== +"@lerna/symlink-binary@3.17.0": + version "3.17.0" + resolved "https://registry.yarnpkg.com/@lerna/symlink-binary/-/symlink-binary-3.17.0.tgz#8f8031b309863814883d3f009877f82e38aef45a" + integrity sha512-RLpy9UY6+3nT5J+5jkM5MZyMmjNHxZIZvXLV+Q3MXrf7Eaa1hNqyynyj4RO95fxbS+EZc4XVSk25DGFQbcRNSQ== dependencies: "@lerna/create-symlink" "3.16.2" "@lerna/package" "3.16.0" fs-extra "^8.1.0" p-map "^2.1.0" -"@lerna/symlink-dependencies@3.16.2": - version "3.16.2" - resolved "https://registry.yarnpkg.com/@lerna/symlink-dependencies/-/symlink-dependencies-3.16.2.tgz#91d9909d35897aebd76a03644a00cd03c4128240" - integrity sha512-wnZqGJQ+Jvr1I3inxrkffrFZfmQI7Ta8gySw/UWCy95QtZWF/f5yk8zVIocCAsjzD0wgb3jJE3CFJ9W5iwWk1A== +"@lerna/symlink-dependencies@3.17.0": + version "3.17.0" + resolved "https://registry.yarnpkg.com/@lerna/symlink-dependencies/-/symlink-dependencies-3.17.0.tgz#48d6360e985865a0e56cd8b51b308a526308784a" + integrity sha512-KmjU5YT1bpt6coOmdFueTJ7DFJL4H1w5eF8yAQ2zsGNTtZ+i5SGFBWpb9AQaw168dydc3s4eu0W0Sirda+F59Q== dependencies: "@lerna/create-symlink" "3.16.2" "@lerna/resolve-symlink" "3.16.0" - "@lerna/symlink-binary" "3.16.2" + "@lerna/symlink-binary" "3.17.0" fs-extra "^8.1.0" p-finally "^1.0.0" p-map "^2.1.0" @@ -1968,23 +1953,23 @@ dependencies: npmlog "^4.1.2" -"@lerna/version@3.16.4": - version "3.16.4" - resolved "https://registry.yarnpkg.com/@lerna/version/-/version-3.16.4.tgz#b5cc37f3ad98358d599c6196c30b6efc396d42bf" - integrity sha512-ikhbMeIn5ljCtWTlHDzO4YvTmpGTX1lWFFIZ79Vd1TNyOr+OUuKLo/+p06mCl2WEdZu0W2s5E9oxfAAQbyDxEg== +"@lerna/version@3.18.0": + version "3.18.0" + resolved "https://registry.yarnpkg.com/@lerna/version/-/version-3.18.0.tgz#81657c913f12eceee1ae499349365fed55440a36" + integrity sha512-mGw5EoQ8wXyofJIHEWNsNWqnTsXlgVvsqePyKkUZTZCsG54ez0ZKpU87EgirxXvj+QDyKgB7X5Dz1hftaX5PSw== dependencies: - "@lerna/check-working-tree" "3.14.2" - "@lerna/child-process" "3.14.2" - "@lerna/collect-updates" "3.16.0" - "@lerna/command" "3.16.0" + "@lerna/check-working-tree" "3.16.5" + "@lerna/child-process" "3.16.5" + "@lerna/collect-updates" "3.18.0" + "@lerna/command" "3.18.0" "@lerna/conventional-commits" "3.16.4" - "@lerna/github-client" "3.16.0" + "@lerna/github-client" "3.16.5" "@lerna/gitlab-client" "3.15.0" "@lerna/output" "3.13.0" "@lerna/prerelease-id-from-version" "3.16.0" "@lerna/prompt" "3.13.0" "@lerna/run-lifecycle" "3.16.2" - "@lerna/run-topologically" "3.16.0" + "@lerna/run-topologically" "3.18.0" "@lerna/validation-error" "3.13.0" chalk "^2.3.1" dedent "^0.7.0" @@ -2184,7 +2169,7 @@ "@styled-system/core" "^5.1.2" "@styled-system/css" "^5.0.23" -"@types/babel__core@^7.1.0": +"@types/babel__core@^7.1.0", "@types/babel__core@^7.1.3": version "7.1.3" resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.1.3.tgz#e441ea7df63cd080dfcd02ab199e6d16a735fc30" integrity sha512-8fBo0UR2CcwWxeX7WIIgJ7lXjasFxoYgRnFHUj+hRvKkpiBJbxhdAPTCY6/ZKM0uxANFVzt4yObSLuTiTnazDA== @@ -2261,6 +2246,18 @@ "@types/istanbul-lib-coverage" "*" "@types/istanbul-lib-report" "*" +"@types/jest-diff@*": + version "20.0.1" + resolved "https://registry.yarnpkg.com/@types/jest-diff/-/jest-diff-20.0.1.tgz#35cc15b9c4f30a18ef21852e255fdb02f6d59b89" + integrity sha512-yALhelO3i0hqZwhjtcr6dYyaLoCHbAMshwtj6cGxTvHZAKXHsYGdff6E8EPw3xLKY0ELUTQ69Q1rQiJENnccMA== + +"@types/jest@^24.0.19": + version "24.0.19" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-24.0.19.tgz#f7036058d2a5844fe922609187c0ad8be430aff5" + integrity sha512-YYiqfSjocv7lk5H/T+v5MjATYjaTMsUkbDnjGqSMoO88jWdtJXJV4ST/7DKZcoMHMBvB2SeSfyOzZfkxXHR5xg== + dependencies: + "@types/jest-diff" "*" + "@types/json-schema@^7.0.3": version "7.0.3" resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.3.tgz#bdfd69d61e464dcc81b25159c270d75a73c1a636" @@ -2283,7 +2280,7 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-12.7.8.tgz#cb1bf6800238898bc2ff6ffa5702c3cadd350708" integrity sha512-FMdVn84tJJdV+xe+53sYiZS4R5yn1mAIxfj+DVoNiQjTYz1+OYmjwEZr1ev9nU0axXwda0QDbYl06QHanRVH3A== -"@types/node@^12.7.12": +"@types/node@^12.11.1", "@types/node@^12.7.12": version "12.11.1" resolved "https://registry.yarnpkg.com/@types/node/-/node-12.11.1.tgz#1fd7b821f798b7fa29f667a1be8f3442bb8922a3" integrity sha512-TJtwsqZ39pqcljJpajeoofYRfeZ7/I/OMUQ5pR4q5wOKf2ocrUvBAZUMhWsOvKx3dVc/aaV5GluBivt0sWqA5A== @@ -2298,6 +2295,26 @@ resolved "https://registry.yarnpkg.com/@types/object-path/-/object-path-0.11.0.tgz#0b744309b2573dc8bf867ef589b6288be998e602" integrity sha512-/tuN8jDbOXcPk+VzEVZzzAgw1Byz7s/itb2YI10qkSyy6nykJH02DuhfrflxVdAdE7AZ91h5X6Cn0dmVdFw2TQ== +"@types/prop-types@*": + version "15.7.3" + resolved "https://registry.yarnpkg.com/@types/prop-types/-/prop-types-15.7.3.tgz#2ab0d5da2e5815f94b0b9d4b95d1e5f243ab2ca7" + integrity sha512-KfRL3PuHmqQLOG+2tGpRO26Ctg+Cq1E01D2DMriKEATHgWLfeNDmq9e29Q9WIky0dQ3NPkd1mzYH8Lm936Z9qw== + +"@types/react-dom@^16.9.2": + version "16.9.2" + resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-16.9.2.tgz#90f9e6c161850be1feb31d2f448121be2a4f3b47" + integrity sha512-hgPbBoI1aTSTvZwo8HYw35UaTldW6n2ETLvHAcfcg1FaOuBV3olmyCe5eMpx2WybWMBPv0MdU2t5GOcQhP+3zA== + dependencies: + "@types/react" "*" + +"@types/react@*", "@types/react@^16.9.9": + version "16.9.9" + resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.9.tgz#a62c6f40f04bc7681be5e20975503a64fe783c3a" + integrity sha512-L+AudFJkDukk+ukInYvpoAPyJK5q1GanFOINOJnM0w6tUgITuWvJ4jyoBPFL7z4/L8hGLd+K/6xR5uUjXu0vVg== + dependencies: + "@types/prop-types" "*" + csstype "^2.2.0" + "@types/resolve@0.0.8": version "0.0.8" resolved "https://registry.yarnpkg.com/@types/resolve/-/resolve-0.0.8.tgz#f26074d238e02659e323ce1a13d041eee280e194" @@ -4349,15 +4366,6 @@ cli-width@^2.0.0: resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.0.tgz#ff19ede8a9a5e579324147b0c11f0fbcbabed639" integrity sha1-/xnt6Kml5XkyQUewwR8PvLq+1jk= -cliui@^4.0.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/cliui/-/cliui-4.1.0.tgz#348422dbe82d800b3022eef4f6ac10bf2e4d1b49" - integrity sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ== - dependencies: - string-width "^2.1.1" - strip-ansi "^4.0.0" - wrap-ansi "^2.0.0" - cliui@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/cliui/-/cliui-5.0.0.tgz#deefcfdb2e800784aa34f46fa08e06851c7bbbc5" @@ -4882,6 +4890,11 @@ cssstyle@^1.0.0: dependencies: cssom "0.3.x" +csstype@^2.2.0: + version "2.6.7" + resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.7.tgz#20b0024c20b6718f4eda3853a1f5a1cce7f5e4a5" + integrity sha512-9Mcn9sFbGBAdmimWb2gLVDtFJzeKtDGIr76TUqmjZrw9LFXBMSU70lcs+C0/7fyCd6iBDqmksUcCOUIkisPHsQ== + csstype@^2.5.7: version "2.6.6" resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.6.tgz#c34f8226a94bbb10c32cc0d714afdf942291fc41" @@ -5793,7 +5806,7 @@ eslint-visitor-keys@^1.0.0, eslint-visitor-keys@^1.1.0: resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.1.0.tgz#e2a82cea84ff246ad6fb57f9bde5b46621459ec2" integrity sha512-8y9YjtM1JBJU/A9Kc+SbaOV4y29sSWckBwMHa+FGtVj5gN/sbnKDf6xJUl+8g7FAij9LVaP8C24DUiH/f/2Z9A== -eslint@^6.4.0: +eslint@^6.5.1: version "6.5.1" resolved "https://registry.yarnpkg.com/eslint/-/eslint-6.5.1.tgz#828e4c469697d43bb586144be152198b91e96ed6" integrity sha512-32h99BoLYStT1iq1v2P9uwpyznQ4M2jRiFB6acitKz52Gqn+vPaMDUTB1bYi1WN4Nquj2w+t+bimYUG83DC55A== @@ -6646,11 +6659,6 @@ genfun@^5.0.0: resolved "https://registry.yarnpkg.com/genfun/-/genfun-5.0.0.tgz#9dd9710a06900a5c4a5bf57aca5da4e52fe76537" integrity sha512-KGDOARWVga7+rnB3z9Sd2Letx515owfk0hSxHGuqjANb1M+x2bGZGqHLiozPsYMdM2OubeMni/Hpwmjq6qIUhA== -get-caller-file@^1.0.1: - version "1.0.3" - resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" - integrity sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w== - get-caller-file@^2.0.1: version "2.0.5" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" @@ -7608,11 +7616,6 @@ invariant@^2.2.2, invariant@^2.2.4: dependencies: loose-envify "^1.0.0" -invert-kv@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-2.0.0.tgz#7393f5afa59ec9ff5f67a27620d11c226e3eec02" - integrity sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA== - ip@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/ip/-/ip-1.1.5.tgz#bdded70114290828c0a039e72ef25f5aaec4354a" @@ -8893,38 +8896,31 @@ lazystream@^1.0.0: dependencies: readable-stream "^2.0.5" -lcid@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/lcid/-/lcid-2.0.0.tgz#6ef5d2df60e52f82eb228a4c373e8d1f397253cf" - integrity sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA== - dependencies: - invert-kv "^2.0.0" - left-pad@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.3.0.tgz#5b8a3a7765dfe001261dde915589e782f8c94d1e" integrity sha512-XI5MPzVNApjAyhQzphX8BkmKsKUxD4LdyK24iZeQGinBN9yTQT3bFlCBy/aVx2HrNcqQGsdot8ghrjyrvMCoEA== -lerna@^3.16.4: - version "3.16.4" - resolved "https://registry.yarnpkg.com/lerna/-/lerna-3.16.4.tgz#158cb4f478b680f46f871d5891f531f3a2cb31ec" - integrity sha512-0HfwXIkqe72lBLZcNO9NMRfylh5Ng1l8tETgYQ260ZdHRbPuaLKE3Wqnd2YYRRkWfwPyEyZO8mZweBR+slVe1A== - dependencies: - "@lerna/add" "3.16.2" - "@lerna/bootstrap" "3.16.2" - "@lerna/changed" "3.16.4" - "@lerna/clean" "3.16.0" - "@lerna/cli" "3.13.0" - "@lerna/create" "3.16.0" - "@lerna/diff" "3.16.0" - "@lerna/exec" "3.16.0" - "@lerna/import" "3.16.0" - "@lerna/init" "3.16.0" - "@lerna/link" "3.16.2" - "@lerna/list" "3.16.0" - "@lerna/publish" "3.16.4" - "@lerna/run" "3.16.0" - "@lerna/version" "3.16.4" +lerna@^3.18.1: + version "3.18.1" + resolved "https://registry.yarnpkg.com/lerna/-/lerna-3.18.1.tgz#ddc3b68fbba09cb71e3d893500ade787e794b828" + integrity sha512-+EAAEgGl+oNeI1TBBW2btHp7NtpCrsRQET/NNCMRyVsl9/8a322t/WcpO9sCsAyEAITBXfhlRVB9rYifFQ6gNA== + dependencies: + "@lerna/add" "3.18.0" + "@lerna/bootstrap" "3.18.0" + "@lerna/changed" "3.18.0" + "@lerna/clean" "3.18.0" + "@lerna/cli" "3.18.0" + "@lerna/create" "3.18.0" + "@lerna/diff" "3.18.0" + "@lerna/exec" "3.18.0" + "@lerna/import" "3.18.0" + "@lerna/init" "3.18.0" + "@lerna/link" "3.18.0" + "@lerna/list" "3.18.0" + "@lerna/publish" "3.18.1" + "@lerna/run" "3.18.0" + "@lerna/version" "3.18.0" import-local "^2.0.0" npmlog "^4.1.2" @@ -9575,13 +9571,6 @@ makeerror@1.0.x: dependencies: tmpl "1.0.x" -map-age-cleaner@^0.1.1: - version "0.1.3" - resolved "https://registry.yarnpkg.com/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz#7d583a7306434c055fe474b0f45078e6e1b4b92a" - integrity sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w== - dependencies: - p-defer "^1.0.0" - map-cache@^0.2.0, map-cache@^0.2.1, map-cache@^0.2.2: version "0.2.2" resolved "https://registry.yarnpkg.com/map-cache/-/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" @@ -9763,15 +9752,6 @@ media-typer@0.3.0: resolved "https://registry.yarnpkg.com/media-typer/-/media-typer-0.3.0.tgz#8710d7af0aa626f8fffa1ce00168545263255748" integrity sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g= -mem@^4.0.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/mem/-/mem-4.3.0.tgz#461af497bc4ae09608cdb2e60eefb69bff744178" - integrity sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w== - dependencies: - map-age-cleaner "^0.1.1" - mimic-fn "^2.0.0" - p-is-promise "^2.0.0" - meow@5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/meow/-/meow-5.0.0.tgz#dfc73d63a9afc714a5e371760eb5c88b91078aa4" @@ -9943,7 +9923,7 @@ mimic-fn@^1.0.0: resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== -mimic-fn@^2.0.0, mimic-fn@^2.1.0: +mimic-fn@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== @@ -10706,15 +10686,6 @@ os-homedir@^1.0.0, os-homedir@^1.0.1: resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" integrity sha1-/7xJiDNuDoM94MFox+8VISGqf7M= -os-locale@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-3.1.0.tgz#a802a6ee17f24c10483ab9935719cef4ed16bf1a" - integrity sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q== - dependencies: - execa "^1.0.0" - lcid "^2.0.0" - mem "^4.0.0" - os-name@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/os-name/-/os-name-3.1.0.tgz#dec19d966296e1cd62d701a5a66ee1ddeae70801" @@ -10745,11 +10716,6 @@ output-file-sync@^2.0.0: is-plain-obj "^1.1.0" mkdirp "^0.5.1" -p-defer@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/p-defer/-/p-defer-1.0.0.tgz#9f6eb182f6c9aa8cd743004a7d4f96b196b0fb0c" - integrity sha1-n26xgvbJqozXQwBKfU+WsZaw+ww= - p-each-series@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/p-each-series/-/p-each-series-1.0.0.tgz#930f3d12dd1f50e7434457a22cd6f04ac6ad7f71" @@ -10767,11 +10733,6 @@ p-finally@^2.0.0: resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-2.0.1.tgz#bd6fcaa9c559a096b680806f4d657b3f0f240561" integrity sha512-vpm09aKwq6H9phqRQzecoDpD8TmVyGw70qmWlyq5onxY7tqyTTFVvxMykxQSQKILBSFlbXpypIw2T1Ml7+DDtw== -p-is-promise@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/p-is-promise/-/p-is-promise-2.1.0.tgz#918cebaea248a62cf7ffab8e3bca8c5f882fc42e" - integrity sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg== - p-limit@^1.1.0: version "1.3.0" resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.3.0.tgz#b86bd5f0c25690911c7590fcbfc2010d54b3ccb8" @@ -11287,10 +11248,10 @@ prettier-plugin-pkg@^0.4.4: resolved "https://registry.yarnpkg.com/prettier-plugin-pkg/-/prettier-plugin-pkg-0.4.4.tgz#e7b20cba16995d04fe22b0aa2fe3974d9dc8a757" integrity sha512-3rIuIjGLoe8tNdG6I1ybAybNxy3O5SgpZsqypxTzPN4hkBtYbGAhBey1ROclKsFpH6SBYny9Y2djXq9y1b+adQ== -prettier-plugin-sh@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/prettier-plugin-sh/-/prettier-plugin-sh-0.2.0.tgz#9f61d642fa4b20e2bf02cbb94dcfa23dfdbf66e4" - integrity sha512-apDAJO78kpnZ/oJ0NmdiEmd7+gnReomdPKvvucejRG6CUrEezWNB9oNyNIKacm6UuGHs2u9YShVY04sr0UFfVw== +prettier-plugin-sh@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/prettier-plugin-sh/-/prettier-plugin-sh-0.2.1.tgz#9729452c216cb43a045d16b40b9881924350c1ac" + integrity sha512-wQVIOneOuM1IJmxRHC85t4r5Fvf4XPMrbekJFLWmuWwCFjpvbgzqyoyS2xlP2PzB/obrMc8Vo8TlxBQ+ElgVuA== dependencies: mvdan-sh "^0.4.0" @@ -11578,10 +11539,10 @@ react-is@^16.8.1, react-is@^16.8.4: resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.10.1.tgz#0612786bf19df406502d935494f0450b40b8294f" integrity sha512-BXUMf9sIOPXXZWqr7+c5SeOKJykyVr2u0UDzEf4LNGc6taGkQe1A9DFD07umCIXz45RLr9oAAwZbAJ0Pkknfaw== -react@^16.10.1: - version "16.10.1" - resolved "https://registry.yarnpkg.com/react/-/react-16.10.1.tgz#967c1e71a2767dfa699e6ba702a00483e3b0573f" - integrity sha512-2bisHwMhxQ3XQz4LiJJwG3360pY965pTl/MRrZYxIBKVj4fOHoDs5aZAkYXGxDRO1Li+SyjTAilQEbOmtQJHzA== +react@^16.10.2: + version "16.10.2" + resolved "https://registry.yarnpkg.com/react/-/react-16.10.2.tgz#a5ede5cdd5c536f745173c8da47bda64797a4cf0" + integrity sha512-MFVIq0DpIhrHFyqLU0S3+4dIcBhhOvBE8bJ/5kHPVOVaGdo0KuiQzpcjCPsf585WvhypqtrMILyoE2th6dT+Lw== dependencies: loose-envify "^1.1.0" object-assign "^4.1.1" @@ -12152,11 +12113,6 @@ require-directory@^2.1.1: resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= -require-main-filename@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" - integrity sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE= - require-main-filename@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz#d0b329ecc7cc0f61649f62215be69af54aa8989b" @@ -12387,10 +12343,10 @@ rollup-pluginutils@^2.5.0, rollup-pluginutils@^2.8.1, rollup-pluginutils@^2.8.2: dependencies: estree-walker "^0.6.1" -rollup@^1.23.1: - version "1.23.1" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-1.23.1.tgz#0315a0f5d0dfb056e6363e1dff05b89ac2da6b8e" - integrity sha512-95C1GZQpr/NIA0kMUQmSjuMDQ45oZfPgDBcN0yZwBG7Kee//m7H68vgIyg+SPuyrTZ5PrXfyLK80OzXeKG5dAA== +rollup@^1.25.0: + version "1.25.0" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-1.25.0.tgz#0c293d16be13000fa69c5a3035ab21a852d04bd7" + integrity sha512-tcf5ThhnhOUaNrxBSABvaaX9uC8hNxgyJpJmDIXaCkKHq/nPocaDz/4F/KBDiUpOt/ThvUxFrUq3XkyWiyXQiQ== dependencies: "@types/estree" "*" "@types/node" "*" @@ -12963,7 +12919,7 @@ string-width@^1.0.1: is-fullwidth-code-point "^1.0.0" strip-ansi "^3.0.0" -"string-width@^1.0.2 || 2", string-width@^2.0.0, string-width@^2.1.0, string-width@^2.1.1: +"string-width@^1.0.2 || 2", string-width@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== @@ -13692,10 +13648,10 @@ typeof-article@^0.1.1: dependencies: kind-of "^3.1.0" -typescript@^3.7.0-beta: - version "3.7.0-beta" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.7.0-beta.tgz#4ad556e0eee14b90ecc39261001690e16e5eeba9" - integrity sha512-4jyCX+IQamrPJxgkABPq9xf+hUN+GWHVxoj+oey1TadCPa4snQl1RKwUba+1dyzYCamwlCxKvZQ3TjyWLhMGBA== +typescript@^3.6.4: + version "3.6.4" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.6.4.tgz#b18752bb3792bc1a0281335f7f6ebf1bbfc5b91d" + integrity sha512-unoCll1+l+YK4i4F8f22TaNVPRHcD9PA3yCuZ8g5e0qGqlVlJ/8FSateOLLSagn+Yg5+ZwuPkL8LFUc0Jcvksg== ua-parser-js@^0.7.20: version "0.7.20" @@ -14412,14 +14368,6 @@ wordwrap@~1.0.0: resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" integrity sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus= -wrap-ansi@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" - integrity sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU= - dependencies: - string-width "^1.0.1" - strip-ansi "^3.0.1" - wrap-ansi@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-5.1.0.tgz#1fd1f67235d5b6d0fee781056001bfb694c03b09" @@ -14527,7 +14475,7 @@ xml-name-validator@^3.0.0: resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== -"y18n@^3.2.1 || ^4.0.0", y18n@^4.0.0: +y18n@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.0.tgz#95ef94f85ecc81d007c264e190a120f0a3c8566b" integrity sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w== @@ -14549,14 +14497,6 @@ yargs-parser@^10.0.0: dependencies: camelcase "^4.1.0" -yargs-parser@^11.1.1: - version "11.1.1" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-11.1.1.tgz#879a0865973bca9f6bab5cbdf3b1c67ec7d3bcf4" - integrity sha512-C6kB/WJDiaxONLJQnF8ccx9SEeoTTLek8RVbaOIsrAUS8VrBEXfmeSnCZxygc+XC2sNMBIwOOnfcxiynjHsVSQ== - dependencies: - camelcase "^5.0.0" - decamelize "^1.2.0" - yargs-parser@^13.1.1: version "13.1.1" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.1.tgz#d26058532aa06d365fe091f6a1fc06b2f7e5eca0" @@ -14565,6 +14505,14 @@ yargs-parser@^13.1.1: camelcase "^5.0.0" decamelize "^1.2.0" +yargs-parser@^15.0.0: + version "15.0.0" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-15.0.0.tgz#cdd7a97490ec836195f59f3f4dbe5ea9e8f75f08" + integrity sha512-xLTUnCMc4JhxrPEPUYD5IBR1mWCK/aT6+RJ/K29JY2y1vD+FhtgKK0AXRWvI262q3QSffAQuTouFIKUuHX89wQ== + dependencies: + camelcase "^5.0.0" + decamelize "^1.2.0" + yargs-parser@^2.4.0, yargs-parser@^2.4.1: version "2.4.1" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-2.4.1.tgz#85568de3cf150ff49fa51825f03a8c880ddcc5c4" @@ -14573,30 +14521,29 @@ yargs-parser@^2.4.0, yargs-parser@^2.4.1: camelcase "^3.0.0" lodash.assign "^4.0.6" -yargs@^12.0.1: - version "12.0.5" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-12.0.5.tgz#05f5997b609647b64f66b81e3b4b10a368e7ad13" - integrity sha512-Lhz8TLaYnxq/2ObqHDql8dX8CJi97oHxrjUcYtzKbbykPtVW9WB+poxI+NM2UIzsMgNCZTIf0AQwsjK5yMAqZw== +yargs@^13.3.0: + version "13.3.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-13.3.0.tgz#4c657a55e07e5f2cf947f8a366567c04a0dedc83" + integrity sha512-2eehun/8ALW8TLoIl7MVaRUrg+yCnenu8B4kBlRxj3GJGDKU1Og7sMXPNm1BYyM1DOJmTZ4YeN/Nwxv+8XJsUA== dependencies: - cliui "^4.0.0" - decamelize "^1.2.0" + cliui "^5.0.0" find-up "^3.0.0" - get-caller-file "^1.0.1" - os-locale "^3.0.0" + get-caller-file "^2.0.1" require-directory "^2.1.1" - require-main-filename "^1.0.1" + require-main-filename "^2.0.0" set-blocking "^2.0.0" - string-width "^2.0.0" + string-width "^3.0.0" which-module "^2.0.0" - y18n "^3.2.1 || ^4.0.0" - yargs-parser "^11.1.1" + y18n "^4.0.0" + yargs-parser "^13.1.1" -yargs@^13.3.0: - version "13.3.0" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-13.3.0.tgz#4c657a55e07e5f2cf947f8a366567c04a0dedc83" - integrity sha512-2eehun/8ALW8TLoIl7MVaRUrg+yCnenu8B4kBlRxj3GJGDKU1Og7sMXPNm1BYyM1DOJmTZ4YeN/Nwxv+8XJsUA== +yargs@^14.2.0: + version "14.2.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-14.2.0.tgz#f116a9242c4ed8668790b40759b4906c276e76c3" + integrity sha512-/is78VKbKs70bVZH7w4YaZea6xcJWOAwkhbR0CFuZBmYtfTYF0xjGJF43AYd8g2Uii1yJwmS5GR2vBmrc32sbg== dependencies: cliui "^5.0.0" + decamelize "^1.2.0" find-up "^3.0.0" get-caller-file "^2.0.1" require-directory "^2.1.1" @@ -14605,7 +14552,7 @@ yargs@^13.3.0: string-width "^3.0.0" which-module "^2.0.0" y18n "^4.0.0" - yargs-parser "^13.1.1" + yargs-parser "^15.0.0" year@^0.2.1: version "0.2.1"