-
Notifications
You must be signed in to change notification settings - Fork 2
/
.travis.yml
49 lines (43 loc) · 1.68 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
language: php
php:
- 5.3
- 5.4
- 5.5
env:
- CAKE_VERSION=2.3.10
- CAKE_VERSION=2.4.10
- CAKE_VERSION=master
before_script:
- git clone --depth 1 git://github.com/cakephp/cakephp --branch $CAKE_VERSION ../cakephp && cd ../cakephp
- git clone --depth 1 git://github.com/facebook/xhprof.git vendors/xhprof
- sh -c "cd vendors/xhprof/extension && phpize && ./configure --enable-xhprof && make && sudo make install"
- echo -ne "[xdebug]\nextension=xhprof.so\nxhprof.output_dir=/tmp" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
- echo 'Configure::write("XHProf.library", dirname(APP) . "/vendors/xhprof/xhprof_lib");' >> app/Config/bootstrap.php
- cp -R ../CakePHP-XHProf plugins/XHProf
- cp plugins/XHProf/.coveralls.yml .coveralls.yml
- mkdir -p build/logs
- echo "<phpunit>
<filter>
<whitelist processUncoveredFilesFromWhitelist=\"true\">
<directory suffix=\".php\">$(pwd)/plugins/XHProf</directory>
<exclude>
<file>$(pwd)/plugins/XHProf/Lib/Panel/XHProfPanel.php</file>
<directory suffix=\".php\">$(pwd)/plugins/XHProf/Test</directory>
</exclude>
</whitelist>
</filter>
<logging>
<log type=\"coverage-clover\" target=\"build/logs/clover.xml\" />
</logging>
</phpunit>" > phpunit.xml
- composer self-update
- composer init --no-interaction
- composer require --dev satooshi/php-coveralls:dev-master
- composer global require 'phpunit/phpunit=3.7.33'
- ln -s ~/.composer/vendor/phpunit/phpunit/PHPUnit vendors/PHPUnit
script:
- ./lib/Cake/Console/cake test XHProf AllXHProf
after_script:
- ./vendor/bin/coveralls
notifications:
email: false