Skip to content

Commit

Permalink
Fix babel-cli tests
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolo-ribaudo committed Jan 16, 2022
1 parent 257843f commit 75735fe
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 13 deletions.
1 change: 0 additions & 1 deletion jest.config.js
Expand Up @@ -31,7 +31,6 @@ module.exports = {
...(isPublishBundle ? ["\\.skip-bundled\\.js$"] : []),
"/eslint/",
"/babel-node/",
"/babel-cli/",
"/babel-register/",
"/babel-helpers/",
],
Expand Down
Expand Up @@ -16,12 +16,12 @@ config <CWD>/.babelrc
programmatic options from @babel/cli
{
"presets": [
"<ROOTDIR>/packages/babel-preset-react"
"<ROOTDIR>/packages/babel-preset-react/lib/index.js"
],
"plugins": [
"<ROOTDIR>/packages/babel-plugin-transform-arrow-functions",
"<ROOTDIR>/packages/babel-plugin-transform-strict-mode",
"<ROOTDIR>/packages/babel-plugin-transform-modules-commonjs"
"<ROOTDIR>/packages/babel-plugin-transform-arrow-functions/lib/index.js",
"<ROOTDIR>/packages/babel-plugin-transform-strict-mode/lib/index.js",
"<ROOTDIR>/packages/babel-plugin-transform-modules-commonjs/lib/index.js"
],
"sourceFileName": "src/foo.js",
"caller": {
Expand Down
Expand Up @@ -110,12 +110,12 @@ config <CWD>/.babelrc
programmatic options from @babel/cli
{
"presets": [
"<ROOTDIR>/packages/babel-preset-react"
"<ROOTDIR>/packages/babel-preset-react/lib/index.js"
],
"plugins": [
"<ROOTDIR>/packages/babel-plugin-transform-arrow-functions",
"<ROOTDIR>/packages/babel-plugin-transform-strict-mode",
"<ROOTDIR>/packages/babel-plugin-transform-modules-commonjs"
"<ROOTDIR>/packages/babel-plugin-transform-arrow-functions/lib/index.js",
"<ROOTDIR>/packages/babel-plugin-transform-strict-mode/lib/index.js",
"<ROOTDIR>/packages/babel-plugin-transform-modules-commonjs/lib/index.js"
],
"configFile": "./my-config.js",
"sourceFileName": "./src/index.js",
Expand Down
8 changes: 4 additions & 4 deletions packages/babel-cli/test/index.js
Expand Up @@ -25,12 +25,12 @@ const outputFileSync = function (filePath, data) {
fs.writeFileSync(filePath, data);
};

const presetLocs = [path.join(rootDir, "./packages/babel-preset-react")];
const presetLocs = [path.join(rootDir, "./packages/babel-preset-react/lib/index.js")];

const pluginLocs = [
path.join(rootDir, "./packages/babel-plugin-transform-arrow-functions"),
path.join(rootDir, "./packages/babel-plugin-transform-strict-mode"),
path.join(rootDir, "./packages/babel-plugin-transform-modules-commonjs"),
path.join(rootDir, "./packages/babel-plugin-transform-arrow-functions/lib/index.js"),
path.join(rootDir, "./packages/babel-plugin-transform-strict-mode/lib/index.js"),
path.join(rootDir, "./packages/babel-plugin-transform-modules-commonjs/lib/index.js"),
].join(",");

const readDir = function (loc, filter) {
Expand Down

0 comments on commit 75735fe

Please sign in to comment.