forked from Bit-Wasp/bitcoin-php
-
Notifications
You must be signed in to change notification settings - Fork 4
/
.travis.yml
60 lines (52 loc) · 1.93 KB
/
.travis.yml
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
language: php
php:
- 5.4
- 5.5
- 5.6
- hhvm
- nightly
env:
- EXT_SECP256K1="-dextension=secp256k1.so"
- EXT_SECP256K1=""
install:
- |
sh -c 'if [ "$EXT_SECP256K1" != "" ]; then \
git clone git://github.com/bitcoin/secp256k1.git libsecp256k1 \
&& cd libsecp256k1 \
&& ./autogen.sh && ./configure && make && sudo make install \
&& cd ..; fi'
- |
sh -c 'if [ "$EXT_SECP256K1" != "" ]; then \
git clone git://github.com/Bit-Wasp/secp256k1-php \
&& cd secp256k1-php/secp256k1 \
&& phpize && ./configure && make && sudo make install \
&& cd ../..; fi'
- |
sh -c 'if [ "" == ""]; then \
cd tests/Data \
&& git clone https://github.com/jonasnick/bitcoinconsensus_testcases.git \
&& cd ../..; fi'
- composer update --prefer-source
script:
- php $EXT_SECP256K1 vendor/bin/phpunit --coverage-clover build/logs/clover.xml
- php vendor/bin/phpcs -n --standard=PSR1,PSR2 --report=full src/
## - php bin/phpmd src/ text build/rulesets/phpmd.xml
after_script:
- wget https://scrutinizer-ci.com/ocular.phar
- sh -c 'if [ "$TRAVIS_PHP_VERSION" != "hhvm" ] && [ "$TRAVIS_PHP_VERSION" != "nightly" ]; then php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml; fi;'
matrix:
fast_finish: true
exclude:
## exclude hhvm + extension because it's a zend extension
- php: hhvm
env: EXT_SECP256K1="-dextension=secp256k1.so"
## exclude nightly + extension until the extension itself actually passes tests
- php: nightly
env: EXT_SECP256K1="-dextension=secp256k1.so"
notifications:
webhooks:
urls:
- https://webhooks.gitter.im/e/75311bf6cc64a613a399
on_success: change # options: [always|never|change] default: always
on_failure: always # options: [always|never|change] default: always
on_start: false # default: false