language: php

php:
  - 5.4
  - 5.5
  - 5.6
  - 7.0
  - hhvm

matrix:
  allow_failures:
    - php: 7.0
    - php: hhvm
  include:
    - php: 5.4
      env:
        - COMPOSER_FLAGS="--prefer-stable --prefer-lowest"
        - PHPUNIT_FLAGS="--coverage-clover build/coverage.xml"
        - COVERAGE=true

install:
  - travis_retry composer self-update
  - travis_retry composer update ${COMPOSER_FLAGS} --prefer-source --no-interaction
  - php -S 127.0.0.1:10000 -t vendor/php-http/adapter-integration-tests/fixture

script: vendor/bin/phpunit ${PHPUNIT_FLAGS}

after_script:
  - 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

language: php

php:
  - 5.4
  - 5.5
  - 5.6
  - 7.0
  - hhvm

matrix:
  allow_failures:
    - php: 7.0
    - php: hhvm
  include:
    - php: 5.4
      env:
        - COMPOSER_FLAGS="--prefer-stable --prefer-lowest"
        - PHPUNIT_FLAGS="--coverage-clover build/coverage.xml"
        - COVERAGE=true

install:
  - travis_retry composer self-update
  - travis_retry composer update ${COMPOSER_FLAGS} --prefer-source --no-interaction
  - php -S 127.0.0.1:10000 -t vendor/php-http/adapter-integration-tests/fixture > /dev/null 2>&1 &

script: vendor/bin/phpunit ${PHPUNIT_FLAGS}

after_script:
  - 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

Fix PHP web server run
Fix PHP web server run
