Skip to content

Commit 36fb683

Browse files
committed
fix a few bugs
1 parent ed4fba2 commit 36fb683

File tree

2 files changed

+11
-9
lines changed

2 files changed

+11
-9
lines changed

.kokoro/system_tests.sh

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -53,18 +53,20 @@ export PULL_REQUEST_NUMBER=$KOKORO_GITHUB_PULL_REQUEST_NUMBER
5353
# Load phpbrew shell
5454
source /root/.phpbrew/bashrc
5555

56-
# decide which php version to use
57-
if [ -z "${GOOGLE_ALT_PROJECT_ID}" ]; then
58-
# By default use PHP 7.4
59-
phpbrew switch $(phpbrew list | grep 7.4)
60-
elif [ "3" -eq ${GOOGLE_ALT_PROJECT_ID: -1} ]; then
61-
phpbrew switch $(phpbrew list | grep 7.3)
56+
# Decide which php version to use.
57+
if [ "3" -eq ${GOOGLE_ALT_PROJECT_ID: -1} ]; then
58+
PHP_VERSION="7.3"
6259
elif [ "1" -eq ${GOOGLE_ALT_PROJECT_ID: -1} ]; then
63-
phpbrew switch $(phpbrew list | grep 7.4)
60+
PHP_VERSION="7.4"
6461
elif [ "2" -eq ${GOOGLE_ALT_PROJECT_ID: -1} ]; then
65-
phpbrew switch $(phpbrew list | grep 8.0)
62+
PHP_VERSION="8.0"
63+
else
64+
# By default use PHP 7.4
65+
PHP_VERSION="7.4"
6666
fi
6767

68+
phpbrew switch $(phpbrew list | grep $PHP_VERSION | cut -c 2-)
69+
6870
# If we are running REST tests, disable gRPC
6971
if [ "${RUN_REST_TESTS_ONLY}" = "true" ]; then
7072
phpbrew ext disable grpc

testing/run_cs_check.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ DIR="${1:-$PROJECT_ROOT}"
2222
cd $PROJECT_ROOT
2323

2424
# install local version of php-cs-fixer 3.0 from composer.json
25-
composer -q install -d testing/
25+
composer install -d testing/
2626

2727
# run php-cs-fixer
2828
PHP_CS_FIXER="php-cs-fixer"

0 commit comments

Comments
 (0)