/
e2e-babel.sh
executable file
路42 lines (31 loc) 路 1.39 KB
/
e2e-babel.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/bin/bash
#==============================================================================#
# SETUP #
#==============================================================================#
# Start in scripts/integration-tests/ even if run from root directory
cd "$(dirname "$0")" || exit
source utils/local-registry.sh
source utils/cleanup.sh
# Echo every command being executed
set -x
# Go to the root of the monorepo
cd ../..
#==============================================================================#
# TEST #
#==============================================================================#
if [ "$BABEL_8_BREAKING" = true ] ; then
# This option is removed in Babel 8
sed -i 's/allowDeclareFields: true,\?/\/* allowDeclareFields: true *\//g' babel.config.js
fi
startLocalRegistry "$PWD"/scripts/integration-tests/verdaccio-config.yml
# We only bump dependencies in the top-level package.json, because workspaces
# already use the workspace: protocol so will get the version in the monorepo
# and not from npm.
node "$PWD"/scripts/integration-tests/utils/bump-babel-dependencies.js
# Build and test
YARN_ENABLE_IMMUTABLE_INSTALLS=false make -j build-standalone-ci
for i in {1..50}; do
echo "RUN NUMBER $i"
BABEL_ENV=test yarn jest --maxWorkers=4 --ci
done
cleanup