cypress and instanbul
This commit is contained in:
@@ -1,7 +1,10 @@
|
||||
#!/bin/sh
|
||||
|
||||
export DISPLAY=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2; exit;}'):0.0
|
||||
export DISPLAY=host.docker.internal:0.0
|
||||
#export DISPLAY=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2; exit;}'):0.0
|
||||
#export DISPLAY=host.docker.internal:0.0
|
||||
rm -r coverage
|
||||
rm -r .nyc_output
|
||||
yarn build:instanbul
|
||||
echo DISPLAY: $DISPLAY
|
||||
yarn cy:$1
|
||||
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
branch=$1
|
||||
url=$2
|
||||
paypal=sandbox
|
||||
|
||||
if [ "$branch" == "" ]; then
|
||||
echo missing branch name
|
||||
@@ -24,12 +23,15 @@ sed -i 's#\(pppReturnURL:\).*#pppReturnURL:"'$url'/checkout/overview\?type=paypa
|
||||
sed -i 's#\(pppCancelURL:\).*#pppCancelURL:"'$url'/checkout/payment\?type=paypal",#g' api/hooks/config.js
|
||||
sed -i 's#\(var paypalMode *=\).*#var paypalMode = "'$paypal'"#g' api/hooks/config.js
|
||||
cat api/hooks/config.js
|
||||
sed -i 's#\(apiBaseURL.*\)"http.*"#\1"'$url'/api/"#g' src/config.ts
|
||||
sed -i 's#\(sentryEnvironment.*\)".*"#\1"'$branch'"#g' src/config.ts
|
||||
|
||||
if [ "$branch" == "master" || "$branch" == "dev" ]; then
|
||||
if [[ "$branch" == "master" || "$branch" == "dev" ]]; then
|
||||
sed -i 's#//\( sentry\\.init.*\)#\1#g' src/config.ts
|
||||
fi
|
||||
|
||||
|
||||
cat src/config.ts
|
||||
|
||||
if [ "$branch" != "master" ]; then
|
||||
sed -i 's#\(namespace:.*\)#\1_'$branch'#g' api/config.yml
|
||||
cat api/config.yml
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user