iranianpep/darksky

View on GitHub
.travis.yml

Summary

Maintainability
Test Coverage
env:
  global:
    - coverage=false
    - CC_TEST_REPORTER_ID=806ffaf1bcd1080b8b6ba4839e7acefdb6508332b18162816e4683307e008fec

language: php

matrix:
  include:
  - php: 7.0
    env: coverage=true
  - php: 7.1
  - php: 7.2
  - php: 7.3
  - php: 7.4

sudo: false

install:
  - composer update

before_script:
  - curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
  - chmod +x ./cc-test-reporter
  - if [[ $coverage = 'true' ]]; then ./cc-test-reporter before-build; fi

script:
  - vendor/bin/phpunit --coverage-clover build/logs/clover.xml

after_script:
    - if [[ $coverage = 'true' ]]; then ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT; fi