Skip to content

Commit d05e75a

Browse files
authored
Check for composer installation failure (php-curl-class#924)
1 parent 3348afb commit d05e75a

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

tests/run.sh

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,17 @@
22

33
set -x
44

5+
errors=()
6+
57
if [[ "${CI}" == "true" ]]; then
68
composer self-update
79
composer install --prefer-source --no-interaction
10+
if [[ "${?}" -ne 0 ]]; then
11+
echo "Error: composer install failed"
12+
errors+=("composer install failed")
13+
fi
814
fi
915

10-
1116
# Use composer's phpunit and phpcs by adding composer bin directory to the path environment variable.
1217
export PATH="${PWD}/vendor/bin:${PATH}"
1318

@@ -21,8 +26,6 @@ echo "CI_PHP_FUTURE_RELEASE: ${CI_PHP_FUTURE_RELEASE}"
2126
php -r "var_dump(phpversion());"
2227
php -r "var_dump(curl_version());"
2328

24-
errors=()
25-
2629
source "run_syntax_check.sh"
2730

2831
source "run_coding_standards_check.sh"

0 commit comments

Comments
 (0)