mirror of
https://github.com/retailcrm/mailgun-php.git
synced 2025-02-16 13:03:13 +03:00
Improve Travis build (#231)
* Improve Travis build * Added more shields * bugfiz * minor * bash fix * Update min version * Remove test code * Refactor
This commit is contained in:
parent
21c95412c6
commit
8c2ffbfd3f
29
.travis.yml
29
.travis.yml
@ -1,17 +1,40 @@
|
|||||||
language: php
|
language: php
|
||||||
|
|
||||||
|
sudo: false
|
||||||
|
|
||||||
|
cache:
|
||||||
|
directories:
|
||||||
|
- $HOME/.composer/cache/files
|
||||||
|
|
||||||
php:
|
php:
|
||||||
- 5.5
|
- 5.5
|
||||||
- 5.6
|
- 5.6
|
||||||
- 7.0
|
- 7.0
|
||||||
|
- 7.1
|
||||||
- hhvm
|
- hhvm
|
||||||
|
|
||||||
|
matrix:
|
||||||
|
fast_finish: true
|
||||||
|
include:
|
||||||
|
- php: 5.5
|
||||||
|
env: COMPOSER_FLAGS="--prefer-stable --prefer-lowest" PREFER_COVERAGE=true
|
||||||
|
|
||||||
install:
|
install:
|
||||||
- travis_retry composer install
|
- travis_retry composer update ${COMPOSER_FLAGS} --prefer-source --no-interaction
|
||||||
|
|
||||||
|
before_script:
|
||||||
|
- TEST_COMMAND="composer test-all"
|
||||||
|
- if ! [[ "$TRAVIS_PULL_REQUEST" = false ]]; then TEST_COMMAND="composer test"; fi
|
||||||
|
- if [[ "$PREFER_COVERAGE" = true ]] && [[ "$TRAVIS_PULL_REQUEST" = false ]]; then TEST_COMMAND="composer test-coverage" COVERAGE=true; fi
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- composer test
|
- echo $TEST_COMMAND
|
||||||
- '[[ "${TRAVIS_PULL_REQUEST}" == "false" ]] && ( composer test-coverage ) || ( echo "Testing PR - No integration tests available")'
|
- $TEST_COMMAND
|
||||||
|
|
||||||
|
after_success:
|
||||||
|
- if [[ "$COVERAGE" = true ]]; then wget https://scrutinizer-ci.com/ocular.phar; fi
|
||||||
|
- if [[ "$COVERAGE" = true ]]; then php ocular.phar code-coverage:upload --format=php-clover build/coverage.xml; fi
|
||||||
|
|
||||||
|
|
||||||
notifications:
|
notifications:
|
||||||
slack:
|
slack:
|
||||||
|
@ -6,9 +6,12 @@ Below are examples to get you started. For additional examples, please see our
|
|||||||
official documentation
|
official documentation
|
||||||
at http://documentation.mailgun.com
|
at http://documentation.mailgun.com
|
||||||
|
|
||||||
[![Latest Stable Version](https://poser.pugx.org/mailgun/mailgun-php/v/stable.png)](https://packagist.org/packages/mailgun/mailgun-php)
|
[![Latest Version](https://img.shields.io/github/release/mailgun/mailgun-php.svg?style=flat-square)](https://github.com/mailgun/mailgun-php/releases)
|
||||||
[![Build Status](https://travis-ci.org/mailgun/mailgun-php.png)](https://travis-ci.org/mailgun/mailgun-php)
|
[![Build Status](https://img.shields.io/travis/mailgun/mailgun-php.svg?style=flat-square)](https://travis-ci.org/mailgun/mailgun-php)
|
||||||
[![StyleCI](https://styleci.io/repos/11654443/shield?branch=master)](https://styleci.io/repos/11654443)
|
[![StyleCI](https://styleci.io/repos/11654443/shield?branch=master)](https://styleci.io/repos/11654443)
|
||||||
|
[![Code Coverage](https://img.shields.io/scrutinizer/coverage/g/mailgun/mailgun-php.svg?style=flat-square)](https://scrutinizer-ci.com/g/mailgun/mailgun-php)
|
||||||
|
[![Quality Score](https://img.shields.io/scrutinizer/g/mailgun/mailgun-php.svg?style=flat-square)](https://scrutinizer-ci.com/g/mailgun/mailgun-php)
|
||||||
|
[![Total Downloads](https://img.shields.io/packagist/dt/mailgun/mailgun-php.svg?style=flat-square)](https://packagist.org/packages/mailgun/mailgun-php)
|
||||||
|
|
||||||
**This is the documentation for dev-master. You find documentation for the latest stable
|
**This is the documentation for dev-master. You find documentation for the latest stable
|
||||||
release [here](https://github.com/mailgun/mailgun-php/tree/v2.1.2).**
|
release [here](https://github.com/mailgun/mailgun-php/tree/v2.1.2).**
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
"php-http/httplug": "^1.0",
|
"php-http/httplug": "^1.0",
|
||||||
"php-http/multipart-stream-builder": "^0.1",
|
"php-http/multipart-stream-builder": "^0.1",
|
||||||
"php-http/message": "^1.0",
|
"php-http/message": "^1.0",
|
||||||
"php-http/client-common": "^1.0",
|
"php-http/client-common": "^1.1",
|
||||||
"php-http/discovery": "^1.0",
|
"php-http/discovery": "^1.0",
|
||||||
"webmozart/assert": "^1.2"
|
"webmozart/assert": "^1.2"
|
||||||
},
|
},
|
||||||
@ -33,6 +33,8 @@
|
|||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test": "vendor/bin/phpunit --testsuite unit && vendor/bin/phpunit --testsuite functional",
|
"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"
|
"test-all": "vendor/bin/phpunit",
|
||||||
|
"test-integration": "vendor/bin/phpunit --testsuite integration",
|
||||||
|
"test-coverage": "vendor/bin/phpunit --coverage-text --coverage-clover=build/coverage.xml"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user