forked from hhvm/hack-codegen
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.travis.sh
More file actions
executable file
·30 lines (26 loc) · 815 Bytes
/
.travis.sh
File metadata and controls
executable file
·30 lines (26 loc) · 815 Bytes
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
#!/bin/bash
set -ex
apt update -y
DEBIAN_FRONTEND=noninteractive apt install -y php-cli zip unzip
hhvm --version
php --version
(
cd $(mktemp -d)
curl https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
)
composer install
hh_client
vendor/bin/hacktest tests/
if !(hhvm --version | grep -q -- -dev); then
vendor/bin/hhast-lint
fi
# Check the codegen hasn't been modified; this is also done as part of the next
# step, but we want to make sure the verify-signatures executable works
bin/hh-codegen-verify-signatures \
examples/dorm/demo/{DormUser.php,DormUserMutator.php}
# Check that they're up-to-date
hhvm examples/dorm/codegen.hack examples/dorm/demo/DormUserSchema.php
if ! git diff --exit-code examples/; then
echo "Demo codegen not up to date."
exit 1
fi