Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
liuxingbaoyu committed Jul 23, 2022
1 parent 6fe5cfb commit 31496cf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
6 changes: 2 additions & 4 deletions scripts/integration-tests/e2e-prettier.sh
Expand Up @@ -32,11 +32,9 @@ yarn --version
# TEST #
#==============================================================================#

# Don't use Yarn 2
export YARN_IGNORE_PATH=1

startLocalRegistry "$root"/verdaccio-config.yml
yarn install
yarn install --no-immutable
yarn info

# Without --runInBand CircleCI hangs.
yarn test "tests/format/(jsx?|misc|typescript|flow|flow-repo)/" --update-snapshot --runInBand
Expand Down
10 changes: 6 additions & 4 deletions scripts/integration-tests/utils/bump-babel-dependencies.js
Expand Up @@ -6,23 +6,25 @@ const packageJSONPath = path.resolve(cwd, "./package.json");
const content = JSON.parse(fs.readFileSync(packageJSONPath));

let bumped = false;
function bumpBabelDependency(dependencies, version) {
function bumpBabelDependency(type, version) {
const dependencies = content[type];
for (const dep of Object.keys(dependencies)) {
if (dep.startsWith("@babel/") && !dependencies[dep].includes(":")) {
dependencies[dep] = version;
console.log(`Bumped ${type}:${dep} to ${version}`);
bumped = true;
}
}
}

if ("peerDependencies" in content) {
bumpBabelDependency(content.peerDependencies, "*");
bumpBabelDependency("peerDependencies", "*");
}
if ("devDependencies" in content) {
bumpBabelDependency(content.devDependencies, "latest");
bumpBabelDependency("devDependencies", "latest");
}
if ("dependencies" in content) {
bumpBabelDependency(content.dependencies, "latest");
bumpBabelDependency("dependencies", "latest");
}

if (bumped) {
Expand Down

0 comments on commit 31496cf

Please sign in to comment.