language: php

php:
  - 5.3.3
  - 5.3
  - 5.4
  - 5.5
  - 5.6
  - 7
  - hhvm

matrix:
  fast_finish: true
  allow_failures:
    - php: 7

install:
  - sudo apt-get -y install pypy python-sphinx graphviz
  - composer selfupdate
  - travis_retry composer update --no-interaction --prefer-source

script:
  - cd docs && make linkcheck && cd ..
  - vendor/bin/phpdoc -d src -t docs-api
  - vendor/bin/phpunit --coverage-text

language: php

php:
  - 5.3.3
  - 5.3
  - 5.4
  - 5.5
  - 5.6
  - 7
  - hhvm

matrix:
  fast_finish: true
  allow_failures:
    - php: 7

before_install:
  - composer selfupdate

install:
  - sudo apt-get -y install pypy python-sphinx graphviz
  - travis_retry composer update --no-interaction --prefer-source

script:
  - cd docs && make linkcheck && cd ..
  - vendor/bin/phpdoc -d src -t docs-api
  - vendor/bin/phpunit --coverage-text

Update composer itself in before_install section
Fix: Update composer itself in before_install section
