SImplefied travis config and added composer scripts (#213)

* SImplefied travis config and added composer scripts

* Use 2 space indentation
This commit is contained in:
Tobias Nyholm 2016-11-11 21:22:46 +01:00 committed by Sean Johnson
parent 0d2916d47f
commit c875890720
3 changed files with 15 additions and 14 deletions

View File

@ -1,19 +1,18 @@
language: php
php:
- 5.5
- 5.6
- 7.0
- hhvm
before_install:
- travis_retry composer self-update
- 5.5
- 5.6
- 7.0
- hhvm
install:
- travis_retry composer install
- travis_retry composer require --dev 'phpunit/php-code-coverage=^2.2.4'
- travis_retry composer install
script:
- phpunit -c phpunit.xml.dist --testsuite unit --coverage-text
- phpunit -c phpunit.xml.dist --testsuite functional --coverage-text
- '[[ "${TRAVIS_PULL_REQUEST}" == "false" ]] && ( phpunit -c phpunit.xml.dist --testsuite
integration --coverage-text ) || ( echo "Testing PR - No integration tests available")'
- composer test
- '[[ "${TRAVIS_PULL_REQUEST}" == "false" ]] && ( composer test-coverage ) || ( echo "Testing PR - No integration tests available")'
notifications:
slack:
rooms:

View File

@ -31,5 +31,8 @@
"email": "travis@mailgunhq.com"
}
],
"minimum-stability": "stable"
"scripts": {
"test": "vendor/bin/phpunit --testsuite unit && vendor/bin/phpunit --testsuite functional",
"test-coverage": "vendor/bin/phpunit --testsuite integration --coverage-text --coverage-clover=build/coverage.xml"
}
}

View File

@ -34,5 +34,4 @@
<directory suffix=".php">src</directory>
</whitelist>
</filter>
</phpunit>