forked from hhvm/hhvm-autoload
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.sh
executable file
·26 lines (22 loc) · 879 Bytes
/
.travis.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
#!/bin/sh
set -ex
hhvm --version
apt-get update -y
apt-get install -y wget curl git
curl https://getcomposer.org/installer | hhvm -d hhvm.jit=0 --php -- /dev/stdin --install-dir=/usr/local/bin --filename=composer
cd /var/source
hhvm -d hhvm.jit=0 /usr/local/bin/composer install
hh_server --check $(pwd)
hhvm -d hhvm.jit=0 vendor/bin/phpunit tests/
bin/hh-autoload
hh_server --check $(pwd)
hhvm -d hhvm.jit=0 vendor/bin/phpunit \
--bootstrap=vendor/hh_autoload.php tests/
HHVM_VERSION=$(hhvm --php -r 'echo HHVM_VERSION_ID;' 2>/dev/null);
if [ $HHVM_VERSION -ge 32002 ]; then
hhvm -d hhvm.php7.all=1 -d hhvm.jit=0 vendor/bin/phpunit tests/
fi
if [ $HHVM_VERSION -ge 32200 -a $HHVM_VERSION -lt 32300 ]; then
echo enable_experimental_tc_features = optional_shape_field, unknown_fields_shape_is_not_subtype_of_known_fields_shape >> .hhconfig
hh_server --check $(pwd)
fi