From 00e13e2f62fe1f493630fff775f0674d464c2c93 Mon Sep 17 00:00:00 2001 From: Greg Magolan Date: Wed, 29 Apr 2020 07:31:43 -0700 Subject: [PATCH] fix(builtin): fix regression in 1.6.0 in linker linking root package when under runfiles Resolves #1823 which had a repro https://github.com/purkhusid/ts-jest-repro. NB: The repo uses ts_library devmode UMD output so the relative require in the source code will be transformed to an absolute require which will include the workspace name. In 1.5.0: ``` .../sandbox/darwin-sandbox/23/execroot/jest_repro/bazel-out/darwin-fastbuild/bin/test.sh.runfiles/jest_repro/lib.test.js const lib_1 = require("jest_repro/lib"); ``` works as it finds ``` .../sandbox/darwin-sandbox/23/execroot/jest_repro/bazel-out/darwin-fastbuild/bin/test.sh.runfiles/jest_repro/node_modules/jest_repro/lib.js ``` where `test.sh.runfiles/jest_repro/node_modules/jest_repro` is a symlink to the root of the output tree setup by the linker: ``` lrwxr-xr-x 1 greg wheel 165 29 Apr 05:56 .../sandbox/darwin-sandbox/6/execroot/jest_repro/bazel-out/darwin-fastbuild/bin/test.sh.runfiles/jest_repro/node_modules/jest_repro -> .../sandbox/darwin-sandbox/6/execroot/jest_repro/bazel-out/darwin-fastbuild/bin/test.sh.runfiles/jest_repro ``` In 1.6.0: Bug introduced in #1850 (thanks for tracking down the culprit @alexeagle) where the root symlink is not created properly when under runfiles (such as a jest_test context). Fix is: ``` let runfilesPath = modulePath; if (runfilesPath.startsWith(`${bin}/`)) { runfilesPath = runfilesPath.slice(bin.length + 1); + } else if (runfilesPath === bin) { + runfilesPath = ''; } ``` in `link_node_modules.ts`. NB: This root workspace symlink will be removed in 2.0 as it causes other unrelated issues. PR for that change is in progress https://github.com/bazelbuild/rules_nodejs/pull/1797. In 2.0, we recommend either using the prodmode esm output of ts_library for jest_test or switching to ts_project where the output flavor is controlled by your tsconfig. An example of using ts_library esm output of ts_library (output_group 'es6_sources') is `under /internal/linker/test/issue_1823_use_ts_library_esm`. It require babel-jest to transform the esm to commonjs. Alternately, you can control the 'es5_sources' module format of ts_library with the `devmode_module` but this can lead to other issues such as the output no longer being compatible with ts_devserver and karma_web_test which require named-UMD or named-AMD. --- internal/linker/index.js | 3 + internal/linker/link_node_modules.ts | 2 + internal/linker/test/issue_1823/BUILD.bazel | 22 +++ .../linker/test/issue_1823/jest.config.js | 3 + internal/linker/test/issue_1823/lib.test.ts | 7 + internal/linker/test/issue_1823/lib.ts | 3 + .../linker/test/issue_1823/ts_jest_test.bzl | 35 ++++ .../issue_1823_use_ts_library_esm/.babelrc | 12 ++ .../issue_1823_use_ts_library_esm/BUILD.bazel | 31 +++ .../jest.config.js | 6 + .../issue_1823_use_ts_library_esm/lib.test.ts | 7 + .../test/issue_1823_use_ts_library_esm/lib.ts | 3 + .../ts_jest_test.bzl | 38 ++++ package.json | 2 + yarn.lock | 177 +++++++++++++++++- 15 files changed, 346 insertions(+), 5 deletions(-) create mode 100644 internal/linker/test/issue_1823/BUILD.bazel create mode 100644 internal/linker/test/issue_1823/jest.config.js create mode 100644 internal/linker/test/issue_1823/lib.test.ts create mode 100644 internal/linker/test/issue_1823/lib.ts create mode 100644 internal/linker/test/issue_1823/ts_jest_test.bzl create mode 100644 internal/linker/test/issue_1823_use_ts_library_esm/.babelrc create mode 100644 internal/linker/test/issue_1823_use_ts_library_esm/BUILD.bazel create mode 100644 internal/linker/test/issue_1823_use_ts_library_esm/jest.config.js create mode 100644 internal/linker/test/issue_1823_use_ts_library_esm/lib.test.ts create mode 100644 internal/linker/test/issue_1823_use_ts_library_esm/lib.ts create mode 100644 internal/linker/test/issue_1823_use_ts_library_esm/ts_jest_test.bzl diff --git a/internal/linker/index.js b/internal/linker/index.js index b77064389c..a3e6394c99 100644 --- a/internal/linker/index.js +++ b/internal/linker/index.js @@ -342,6 +342,9 @@ function main(args, runfiles) { if (runfilesPath.startsWith(`${bin}/`)) { runfilesPath = runfilesPath.slice(bin.length + 1); } + else if (runfilesPath === bin) { + runfilesPath = ''; + } const externalPrefix = 'external/'; if (runfilesPath.startsWith(externalPrefix)) { runfilesPath = runfilesPath.slice(externalPrefix.length); diff --git a/internal/linker/link_node_modules.ts b/internal/linker/link_node_modules.ts index 093c65dc62..b0346b72ab 100644 --- a/internal/linker/link_node_modules.ts +++ b/internal/linker/link_node_modules.ts @@ -571,6 +571,8 @@ export async function main(args: string[], runfiles: Runfiles) { let runfilesPath = modulePath; if (runfilesPath.startsWith(`${bin}/`)) { runfilesPath = runfilesPath.slice(bin.length + 1); + } else if (runfilesPath === bin) { + runfilesPath = ''; } const externalPrefix = 'external/'; if (runfilesPath.startsWith(externalPrefix)) { diff --git a/internal/linker/test/issue_1823/BUILD.bazel b/internal/linker/test/issue_1823/BUILD.bazel new file mode 100644 index 0000000000..85ea44a1d9 --- /dev/null +++ b/internal/linker/test/issue_1823/BUILD.bazel @@ -0,0 +1,22 @@ +load("@npm_bazel_typescript//:index.bzl", "ts_library") +load(":ts_jest_test.bzl", "ts_jest_test") + +ts_library( + name = "lib", + srcs = [ + "lib.ts", + ], + deps = [ + ], +) + +ts_jest_test( + name = "test", + srcs = [ + "lib.test.ts", + ], + jest_config = "jest.config.js", + deps = [ + ":lib", + ], +) diff --git a/internal/linker/test/issue_1823/jest.config.js b/internal/linker/test/issue_1823/jest.config.js new file mode 100644 index 0000000000..25c9bac510 --- /dev/null +++ b/internal/linker/test/issue_1823/jest.config.js @@ -0,0 +1,3 @@ +module.exports = { + testEnvironment: 'node', +}; diff --git a/internal/linker/test/issue_1823/lib.test.ts b/internal/linker/test/issue_1823/lib.test.ts new file mode 100644 index 0000000000..0ea73f6237 --- /dev/null +++ b/internal/linker/test/issue_1823/lib.test.ts @@ -0,0 +1,7 @@ +import {doStuff} from './lib'; + +describe('doStuff', () => { + it('should do some stuff', () => { + expect(doStuff('boom')).toContain('boom'); + }); +}); diff --git a/internal/linker/test/issue_1823/lib.ts b/internal/linker/test/issue_1823/lib.ts new file mode 100644 index 0000000000..d7318214c4 --- /dev/null +++ b/internal/linker/test/issue_1823/lib.ts @@ -0,0 +1,3 @@ +export function doStuff(a: string): string { + return a +} \ No newline at end of file diff --git a/internal/linker/test/issue_1823/ts_jest_test.bzl b/internal/linker/test/issue_1823/ts_jest_test.bzl new file mode 100644 index 0000000000..4cabcce682 --- /dev/null +++ b/internal/linker/test/issue_1823/ts_jest_test.bzl @@ -0,0 +1,35 @@ +"""Simple macro around jest_test""" + +load("@npm//jest-cli:index.bzl", _jest_test = "jest_test") +load("@npm_bazel_typescript//:index.bzl", "ts_library") + +def ts_jest_test(name, srcs, jest_config, deps = [], data = [], **kwargs): + """A macro around the autogenerated jest_test rule that takes typescript sources + +Uses ts_library devmode UMD output""" + + ts_library( + name = "%s_ts" % name, + srcs = srcs, + data = data, + deps = deps + ["@npm//@types/jest"], + ) + native.filegroup( + name = "%s_umd" % name, + srcs = [":%s_ts" % name], + output_group = "es5_sources", + ) + + args = [ + "--no-cache", + "--no-watchman", + "--ci", + ] + args.extend(["--config", "$(rootpath %s)" % jest_config]) + + _jest_test( + name = name, + data = [jest_config, ":%s_umd" % name] + deps + data, + args = args, + **kwargs + ) diff --git a/internal/linker/test/issue_1823_use_ts_library_esm/.babelrc b/internal/linker/test/issue_1823_use_ts_library_esm/.babelrc new file mode 100644 index 0000000000..af2cb75a9a --- /dev/null +++ b/internal/linker/test/issue_1823_use_ts_library_esm/.babelrc @@ -0,0 +1,12 @@ +{ + "presets": [ + [ + "@babel/preset-env", + { + "targets": { + "node": "current", + }, + }, + ], + ] +} \ No newline at end of file diff --git a/internal/linker/test/issue_1823_use_ts_library_esm/BUILD.bazel b/internal/linker/test/issue_1823_use_ts_library_esm/BUILD.bazel new file mode 100644 index 0000000000..8496399567 --- /dev/null +++ b/internal/linker/test/issue_1823_use_ts_library_esm/BUILD.bazel @@ -0,0 +1,31 @@ +load("@npm_bazel_typescript//:index.bzl", "ts_library") +load(":ts_jest_test.bzl", "ts_jest_test") + +ts_library( + name = "lib", + srcs = [ + "lib.ts", + ], + # NB: hacky hidden configuration setting so that es6_sources does not include tsickle + # .externs.js outputs + runtime = "nodejs", + deps = [ + "@npm//@types/node", + ], +) + +ts_jest_test( + name = "test", + srcs = [ + "lib.test.ts", + ], + data = [ + ".babelrc", + ], + jest_config = "jest.config.js", + deps = [ + ":lib", + "@npm//@babel/preset-env", + "@npm//babel-jest", + ], +) diff --git a/internal/linker/test/issue_1823_use_ts_library_esm/jest.config.js b/internal/linker/test/issue_1823_use_ts_library_esm/jest.config.js new file mode 100644 index 0000000000..5aa8b74547 --- /dev/null +++ b/internal/linker/test/issue_1823_use_ts_library_esm/jest.config.js @@ -0,0 +1,6 @@ +module.exports = { + testEnvironment: 'node', + transform: {'^.+\\.mjs?$': 'babel-jest'}, + testMatch: ['**/?(*.)(spec|test).?(m)js?(x)'], + moduleFileExtensions: ['js', 'mjs'], +}; diff --git a/internal/linker/test/issue_1823_use_ts_library_esm/lib.test.ts b/internal/linker/test/issue_1823_use_ts_library_esm/lib.test.ts new file mode 100644 index 0000000000..0ea73f6237 --- /dev/null +++ b/internal/linker/test/issue_1823_use_ts_library_esm/lib.test.ts @@ -0,0 +1,7 @@ +import {doStuff} from './lib'; + +describe('doStuff', () => { + it('should do some stuff', () => { + expect(doStuff('boom')).toContain('boom'); + }); +}); diff --git a/internal/linker/test/issue_1823_use_ts_library_esm/lib.ts b/internal/linker/test/issue_1823_use_ts_library_esm/lib.ts new file mode 100644 index 0000000000..d7318214c4 --- /dev/null +++ b/internal/linker/test/issue_1823_use_ts_library_esm/lib.ts @@ -0,0 +1,3 @@ +export function doStuff(a: string): string { + return a +} \ No newline at end of file diff --git a/internal/linker/test/issue_1823_use_ts_library_esm/ts_jest_test.bzl b/internal/linker/test/issue_1823_use_ts_library_esm/ts_jest_test.bzl new file mode 100644 index 0000000000..8de460e710 --- /dev/null +++ b/internal/linker/test/issue_1823_use_ts_library_esm/ts_jest_test.bzl @@ -0,0 +1,38 @@ +"""Simple macro around jest_test""" + +load("@npm//jest-cli:index.bzl", _jest_test = "jest_test") +load("@npm_bazel_typescript//:index.bzl", "ts_library") + +def ts_jest_test(name, srcs, jest_config, deps = [], data = [], **kwargs): + """A macro around the autogenerated jest_test rule that takes typescript sources + +Uses ts_library prodmode ems output""" + + ts_library( + name = "%s_ts" % name, + srcs = srcs, + data = data, + deps = deps + ["@npm//@types/jest"], + # NB: hacky hidden configuration setting so that es6_sources does not include tsickle + # .externs.js outputs + runtime = "nodejs", + ) + native.filegroup( + name = "%s_esm" % name, + srcs = [":%s_ts" % name], + output_group = "es6_sources", + ) + + args = [ + "--no-cache", + "--no-watchman", + "--ci", + ] + args.extend(["--config", "$(rootpath %s)" % jest_config]) + + _jest_test( + name = name, + data = [jest_config, ":%s_esm" % name] + deps + data, + templated_args = args, + **kwargs + ) diff --git a/package.json b/package.json index a7c9e1a5c1..5cc5a4e533 100644 --- a/package.json +++ b/package.json @@ -26,8 +26,10 @@ "@gregmagolan/test-a": "0.0.5", "@types/hammerjs": "2.0.35", "@types/jasmine": "~3.3.13", + "@types/jest": "24.9.0", "@types/node": "^12.0.0", "@types/semver": "6.2.0", + "babel-jest": "^25.5.1", "bazel_workspaces": "file:./tools/npm_packages/bazel_workspaces", "clang-format": "1.2.2", "conventional-changelog-cli": "^2.0.21", diff --git a/yarn.lock b/yarn.lock index f5b4a465cb..61ce916c4a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -880,7 +880,7 @@ "@babel/parser" "^7.6.0" "@babel/types" "^7.6.0" -"@babel/template@^7.7.4", "@babel/template@^7.8.3", "@babel/template@^7.8.6": +"@babel/template@^7.3.3", "@babel/template@^7.7.4", "@babel/template@^7.8.3", "@babel/template@^7.8.6": version "7.8.6" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.8.6.tgz#86b22af15f828dfb086474f964dcc3e39c43ce2b" integrity sha512-zbMsPMy/v0PWFZEhQJ66bqjhH+z0JgMoBWuikXybgG3Gkd/3t5oQ1Rw2WQhnSrsOmsKXnZOx15tkC4qON/+JPg== @@ -928,7 +928,7 @@ lodash "^4.17.13" to-fast-properties "^2.0.0" -"@babel/types@^7.3.0", "@babel/types@^7.8.3", "@babel/types@^7.8.6", "@babel/types@^7.9.0", "@babel/types@^7.9.5": +"@babel/types@^7.3.0", "@babel/types@^7.3.3", "@babel/types@^7.8.3", "@babel/types@^7.8.6", "@babel/types@^7.9.0", "@babel/types@^7.9.5": version "7.9.5" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.9.5.tgz#89231f82915a8a566a703b3b20133f73da6b9444" integrity sha512-XjnvNqenk818r5zMaba+sLQjnbda31UfUURv3ei0qPQw4u+j2jMyJ5b11y8ZHYTRSI3NnInQkkkRT4fLqqPdHg== @@ -1335,6 +1335,37 @@ source-map "^0.6.1" write-file-atomic "^3.0.0" +"@jest/transform@^25.5.1": + version "25.5.1" + resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-25.5.1.tgz#0469ddc17699dd2bf985db55fa0fb9309f5c2db3" + integrity sha512-Y8CEoVwXb4QwA6Y/9uDkn0Xfz0finGkieuV0xkdF9UtZGJeLukD5nLkaVrVsODB1ojRWlaoD0AJZpVHCSnJEvg== + dependencies: + "@babel/core" "^7.1.0" + "@jest/types" "^25.5.0" + babel-plugin-istanbul "^6.0.0" + chalk "^3.0.0" + convert-source-map "^1.4.0" + fast-json-stable-stringify "^2.0.0" + graceful-fs "^4.2.4" + jest-haste-map "^25.5.1" + jest-regex-util "^25.2.6" + jest-util "^25.5.0" + micromatch "^4.0.2" + pirates "^4.0.1" + realpath-native "^2.0.0" + slash "^3.0.0" + source-map "^0.6.1" + write-file-atomic "^3.0.0" + +"@jest/types@^24.9.0": + version "24.9.0" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-24.9.0.tgz#63cb26cb7500d069e5a389441a7c6ab5e909fc59" + integrity sha512-XKK7ze1apu5JWQ5eZjHITP66AX+QsLlbaJRBGYr8pNzwcAE2JVkwnf0yqjHTsDRcjR0mujy/NmZMXw5kl+kGBw== + dependencies: + "@types/istanbul-lib-coverage" "^2.0.0" + "@types/istanbul-reports" "^1.1.1" + "@types/yargs" "^13.0.0" + "@jest/types@^25.3.0": version "25.3.0" resolved "https://registry.yarnpkg.com/@jest/types/-/types-25.3.0.tgz#88f94b277a1d028fd7117bc1f74451e0fc2131e7" @@ -1345,6 +1376,16 @@ "@types/yargs" "^15.0.0" chalk "^3.0.0" +"@jest/types@^25.5.0": + version "25.5.0" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-25.5.0.tgz#4d6a4793f7b9599fc3680877b856a97dbccf2a9d" + integrity sha512-OXD0RgQ86Tu3MazKo8bnrkDRaDXXMGUqd+kTtLtK1Zb7CRzQcaSRPPPV37SvYTdevXEBVxe0HXylEjs8ibkmCw== + dependencies: + "@types/istanbul-lib-coverage" "^2.0.0" + "@types/istanbul-reports" "^1.1.1" + "@types/yargs" "^15.0.0" + chalk "^3.0.0" + "@marionebl/sander@^0.6.0": version "0.6.1" resolved "https://registry.yarnpkg.com/@marionebl/sander/-/sander-0.6.1.tgz#1958965874f24bc51be48875feb50d642fc41f7b" @@ -1520,6 +1561,13 @@ resolved "https://registry.yarnpkg.com/@types/estree/-/estree-0.0.39.tgz#e177e699ee1b8c22d23174caaa7422644389509f" integrity sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw== +"@types/graceful-fs@^4.1.2": + version "4.1.3" + resolved "https://registry.yarnpkg.com/@types/graceful-fs/-/graceful-fs-4.1.3.tgz#039af35fe26bec35003e8d86d2ee9c586354348f" + integrity sha512-AiHRaEB50LQg0pZmm659vNBb9f4SJ0qrAnteuzhSeAUcJKxoYgEnprg/83kppCnc2zvtCKbdZry1a5pVY3lOTQ== + dependencies: + "@types/node" "*" + "@types/hammerjs@2.0.35": version "2.0.35" resolved "https://registry.yarnpkg.com/@types/hammerjs/-/hammerjs-2.0.35.tgz#7b7c950c7d54593e23bffc8d2b4feba9866a7277" @@ -1550,6 +1598,13 @@ resolved "https://registry.yarnpkg.com/@types/jasmine/-/jasmine-3.3.16.tgz#7c84074f5d7f84da9a14f816ccfb9aeb4da13f27" integrity sha512-Nveep4zKGby8uIvG2AEUyYOwZS8uVeHK9TgbuWYSawUDDdIgfhCKz28QzamTo//Jk7Ztt9PO3f+vzlB6a4GV1Q== +"@types/jest@24.9.0": + version "24.9.0" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-24.9.0.tgz#78c6991cd1734cf0d390be24875e310bb0a9fb74" + integrity sha512-dXvuABY9nM1xgsXlOtLQXJKdacxZJd7AtvLsKZ/0b57ruMXDKCOXAC/M75GbllQX6o1pcZ5hAG4JzYy7Z/wM2w== + dependencies: + jest-diff "^24.3.0" + "@types/long@^4.0.0": version "4.0.0" resolved "https://registry.yarnpkg.com/@types/long/-/long-4.0.0.tgz#719551d2352d301ac8b81db732acb6bdc28dbdef" @@ -1617,6 +1672,13 @@ resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-15.0.0.tgz#cb3f9f741869e20cce330ffbeb9271590483882d" integrity sha512-FA/BWv8t8ZWJ+gEOnLLd8ygxH/2UFbAvgEonyfN6yWGLKc7zVjbpl2Y4CTjid9h2RfgPP6SEt6uHwEOply00yw== +"@types/yargs@^13.0.0": + version "13.0.8" + resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-13.0.8.tgz#a38c22def2f1c2068f8971acb3ea734eb3c64a99" + integrity sha512-XAvHLwG7UQ+8M4caKIH0ZozIOYay5fQkAgyIXegXT9jPtdIGdhga+sUEdAr1CiG46aB+c64xQEYyEzlwWVTNzA== + dependencies: + "@types/yargs-parser" "*" + "@types/yargs@^15.0.0": version "15.0.4" resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-15.0.4.tgz#7e5d0f8ca25e9d5849f2ea443cf7c402decd8299" @@ -1770,7 +1832,7 @@ ansi-regex@^3.0.0: resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= -ansi-regex@^4.1.0: +ansi-regex@^4.0.0, ansi-regex@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997" integrity sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg== @@ -2020,6 +2082,20 @@ babel-jest@^25.3.0: chalk "^3.0.0" slash "^3.0.0" +babel-jest@^25.5.1: + version "25.5.1" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-25.5.1.tgz#bc2e6101f849d6f6aec09720ffc7bc5332e62853" + integrity sha512-9dA9+GmMjIzgPnYtkhBg73gOo/RHqPmLruP3BaGL4KEX3Dwz6pI8auSN8G8+iuEG90+GSswyKvslN+JYSaacaQ== + dependencies: + "@jest/transform" "^25.5.1" + "@jest/types" "^25.5.0" + "@types/babel__core" "^7.1.7" + babel-plugin-istanbul "^6.0.0" + babel-preset-jest "^25.5.0" + chalk "^3.0.0" + graceful-fs "^4.2.4" + slash "^3.0.0" + babel-plugin-dynamic-import-node@^2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.0.tgz#f00f507bdaa3c3e3ff6e7e5e98d90a7acab96f7f" @@ -2045,6 +2121,15 @@ babel-plugin-jest-hoist@^25.2.6: dependencies: "@types/babel__traverse" "^7.0.6" +babel-plugin-jest-hoist@^25.5.0: + version "25.5.0" + resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-25.5.0.tgz#129c80ba5c7fc75baf3a45b93e2e372d57ca2677" + integrity sha512-u+/W+WAjMlvoocYGTwthAiQSxDcJAyHpQ6oWlHdFZaaN+Rlk8Q7iiwDPg2lN/FyJtAYnKjFxbn7xus4HCFkg5g== + dependencies: + "@babel/template" "^7.3.3" + "@babel/types" "^7.3.3" + "@types/babel__traverse" "^7.0.6" + babel-polyfill@6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-polyfill/-/babel-polyfill-6.26.0.tgz#379937abc67d7895970adc621f284cd966cf2153" @@ -2078,6 +2163,14 @@ babel-preset-jest@^25.3.0: babel-plugin-jest-hoist "^25.2.6" babel-preset-current-node-syntax "^0.1.2" +babel-preset-jest@^25.5.0: + version "25.5.0" + resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-25.5.0.tgz#c1d7f191829487a907764c65307faa0e66590b49" + integrity sha512-8ZczygctQkBU+63DtSOKGh7tFL0CeCuz+1ieud9lJ1WPQ9O6A1a/r+LGn6Y705PA6whHQ3T1XuB/PmpfNYf8Fw== + dependencies: + babel-plugin-jest-hoist "^25.5.0" + babel-preset-current-node-syntax "^0.1.2" + babel-runtime@^6.23.0, babel-runtime@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe" @@ -3396,6 +3489,11 @@ didyoumean2@2.0.4: lodash.deburr "^4.1.0" ramda "^0.26.1" +diff-sequences@^24.9.0: + version "24.9.0" + resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-24.9.0.tgz#5715d6244e2aa65f48bba0bc972db0b0b11e95b5" + integrity sha512-Dj6Wk3tWyTE+Fo1rW8v0Xhwk80um6yFYKbuAxc9c3EZxIHFDYwbi34Uk42u1CdnIiVorvt4RmlSDjIPyzGC2ew== + diff-sequences@^25.2.6: version "25.2.6" resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-25.2.6.tgz#5f467c00edd35352b7bca46d7927d60e687a76dd" @@ -4460,6 +4558,11 @@ graceful-fs@^4.1.15, graceful-fs@^4.2.2, graceful-fs@^4.2.3: resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.3.tgz#4a12ff1b60376ef09862c2093edd908328be8423" integrity sha512-a30VEBm4PEdx1dRB7MFK7BejejvCvBronbLjht+sHuGYj8PHs7M/5Z+rt5lw551vZ7yfTCj4Vuyy3mSJytDWRQ== +graceful-fs@^4.2.4: + version "4.2.4" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.4.tgz#2256bde14d3632958c465ebc96dc467ca07a29fb" + integrity sha512-WjKPNJF79dtJAVniUlGGWHYGz2jWxT6VhN/4m1NdkbZ2nOsEF+cI1Edgql5zCRhs/VsQYRvrXctxktVXZUkixw== + growly@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/growly/-/growly-1.3.0.tgz#f10748cbe76af964b7c96c93c6bcc28af120c081" @@ -5409,6 +5512,16 @@ jest-config@^25.3.0: pretty-format "^25.3.0" realpath-native "^2.0.0" +jest-diff@^24.3.0: + version "24.9.0" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-24.9.0.tgz#931b7d0d5778a1baf7452cb816e325e3724055da" + integrity sha512-qMfrTs8AdJE2iqrTp0hzh7kTd2PQWrsFyj9tORoKmu32xjPjeE4NyjVRDz8ybYwqS2ik8N4hsIpiVTyFeo2lBQ== + dependencies: + chalk "^2.0.1" + diff-sequences "^24.9.0" + jest-get-type "^24.9.0" + pretty-format "^24.9.0" + jest-diff@^25.3.0: version "25.3.0" resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-25.3.0.tgz#0d7d6f5d6171e5dacde9e05be47b3615e147c26f" @@ -5461,6 +5574,11 @@ jest-environment-node@^25.3.0: jest-util "^25.3.0" semver "^6.3.0" +jest-get-type@^24.9.0: + version "24.9.0" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-24.9.0.tgz#1684a0c8a50f2e4901b6644ae861f579eed2ef0e" + integrity sha512-lUseMzAley4LhIcpSP9Jf+fTrQ4a1yHQwLNeeVa2cEmbCGeoZAtYPOIv8JaxLD/sUpKxetKGP+gsHl8f8TSj8Q== + jest-get-type@^25.2.6: version "25.2.6" resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-25.2.6.tgz#0b0a32fab8908b44d508be81681487dbabb8d877" @@ -5485,6 +5603,26 @@ jest-haste-map@^25.3.0: optionalDependencies: fsevents "^2.1.2" +jest-haste-map@^25.5.1: + version "25.5.1" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-25.5.1.tgz#1df10f716c1d94e60a1ebf7798c9fb3da2620943" + integrity sha512-dddgh9UZjV7SCDQUrQ+5t9yy8iEgKc1AKqZR9YDww8xsVOtzPQSMVLDChc21+g29oTRexb9/B0bIlZL+sWmvAQ== + dependencies: + "@jest/types" "^25.5.0" + "@types/graceful-fs" "^4.1.2" + anymatch "^3.0.3" + fb-watchman "^2.0.0" + graceful-fs "^4.2.4" + jest-serializer "^25.5.0" + jest-util "^25.5.0" + jest-worker "^25.5.0" + micromatch "^4.0.2" + sane "^4.0.3" + walker "^1.0.7" + which "^2.0.2" + optionalDependencies: + fsevents "^2.1.2" + jest-jasmine2@^25.3.0: version "25.3.0" resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-25.3.0.tgz#16ae4f68adef65fb45001b26c864bcbcbf972830" @@ -5633,7 +5771,7 @@ jest-runtime@^25.3.0: strip-bom "^4.0.0" yargs "^15.3.1" -jest-serializer@24.3.0, jest-serializer@^25.2.6: +jest-serializer@24.3.0, jest-serializer@^25.2.6, jest-serializer@^25.5.0: version "24.3.0" resolved "https://registry.yarnpkg.com/jest-serializer/-/jest-serializer-24.3.0.tgz#074e307300d1451617cf2630d11543ee4f74a1c8" integrity sha512-RiSpqo2OFbVLJN/PgAOwQIUeHDfss6NBUDTLhjiJM8Bb5rMrwRqHfkaqahIsOf9cXXB5UjcqDCzbQ7AIoMqWkg== @@ -5668,6 +5806,17 @@ jest-util@^25.3.0: is-ci "^2.0.0" make-dir "^3.0.0" +jest-util@^25.5.0: + version "25.5.0" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-25.5.0.tgz#31c63b5d6e901274d264a4fec849230aa3fa35b0" + integrity sha512-KVlX+WWg1zUTB9ktvhsg2PXZVdkI1NBevOJSkTKYAyXyH4QSvh+Lay/e/v+bmaFfrkfx43xD8QTfgobzlEXdIA== + dependencies: + "@jest/types" "^25.5.0" + chalk "^3.0.0" + graceful-fs "^4.2.4" + is-ci "^2.0.0" + make-dir "^3.0.0" + jest-validate@^25.3.0: version "25.3.0" resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-25.3.0.tgz#eb95fdee0039647bcd5d4be641b21e4a142a880c" @@ -5705,6 +5854,14 @@ jest-worker@^25.2.6: merge-stream "^2.0.0" supports-color "^7.0.0" +jest-worker@^25.5.0: + version "25.5.0" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-25.5.0.tgz#2611d071b79cea0f43ee57a3d118593ac1547db1" + integrity sha512-/dsSmUkIy5EBGfv/IjjqmFxrNAUpBERfGs1oHROyD7yxjG/w+t0GOJDX8O1k32ySmd7+a5IhnJU2qQFcJ4n1vw== + dependencies: + merge-stream "^2.0.0" + supports-color "^7.0.0" + jest@~25.3.0: version "25.3.0" resolved "https://registry.yarnpkg.com/jest/-/jest-25.3.0.tgz#7a5e59741d94b8662664c77a9f346246d6bf228b" @@ -7696,6 +7853,16 @@ prettier@^1.7.4: resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.18.2.tgz#6823e7c5900017b4bd3acf46fe9ac4b4d7bda9ea" integrity sha512-OeHeMc0JhFE9idD4ZdtNibzY0+TPHSpSSb9h8FqtP+YnoZZ1sl8Vc9b1sasjfymH3SonAF4QcA2+mzHPhMvIiw== +pretty-format@^24.9.0: + version "24.9.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-24.9.0.tgz#12fac31b37019a4eea3c11aa9a959eb7628aa7c9" + integrity sha512-00ZMZUiHaJrNfk33guavqgvfJS30sLYf0f8+Srklv0AMPodGGHcoHgksZ3OThYnIvOd+8yMCn0YiEOogjlgsnA== + dependencies: + "@jest/types" "^24.9.0" + ansi-regex "^4.0.0" + ansi-styles "^3.2.0" + react-is "^16.8.4" + pretty-format@^25.3.0: version "25.3.0" resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-25.3.0.tgz#d0a4f988ff4a6cd350342fdabbb809aeb4d49ad5" @@ -7948,7 +8115,7 @@ rc@^1.0.1, rc@^1.1.6, rc@^1.2.7: minimist "^1.2.0" strip-json-comments "~2.0.1" -react-is@^16.12.0: +react-is@^16.12.0, react-is@^16.8.4: version "16.13.1" resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.13.1.tgz#789729a4dc36de2999dc156dd6c1d9c18cea56a4" integrity sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==