language: php

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

# faster builds on new travis setup not using sudo
sudo: false

# cache vendor dirs
cache:
  directories:
    - $HOME/.composer/cache

install:
  - travis_retry composer self-update && composer --version
  - travis_retry composer global require "fxp/composer-asset-plugin:~1.1.0"
  - travis_retry composer update --dev --prefer-dist --no-interaction
# setup application:
  - |
    ./init --env=Development
    sed -i s/root/travis/ common/config/main-local.php
    sed -i "s/'cookieValidationKey' => ''/'cookieValidationKey' => 'testkey'/" frontend/config/main.php
    sed -i "s/'cookieValidationKey' => ''/'cookieValidationKey' => 'testkey'/" backend/config/main.php
    sed -i "s/'cookieValidationKey' => ''/'cookieValidationKey' => 'testkey'/" api/config/main.php
before_script:
  - mysql -e 'CREATE DATABASE yii2_enhanced_test;'
  - php yii_test migrate --interactive=0

script:
  - composer validate --strict
  - composer exec codecept run




language: php

php:
  - 5.5
  - 5.6
  - 7.0
#  - hhvm

# faster builds on new travis setup not using sudo
sudo: false

# cache vendor dirs
cache:
  directories:
    - $HOME/.composer/cache

install:
  - travis_retry composer self-update && composer --version
  - travis_retry composer global require "fxp/composer-asset-plugin:~1.1.0"
  - travis_retry composer update --dev --prefer-dist --no-interaction
# setup application:
  - |
    ./init --env=Development
    sed -i s/root/travis/ common/config/main-local.php
    sed -i "s/'cookieValidationKey' => ''/'cookieValidationKey' => 'testkey'/" frontend/config/main.php
    sed -i "s/'cookieValidationKey' => ''/'cookieValidationKey' => 'testkey'/" backend/config/main.php
    sed -i "s/'cookieValidationKey' => ''/'cookieValidationKey' => 'testkey'/" api/config/main.php
before_script:
  - mysql -e 'CREATE DATABASE yii2_enhanced_test;'
  - php yii_test migrate --interactive=0

script:
  - composer validate --strict
  - composer exec codecept run




Remove 5.4 because guzzle does not support it
Remove 5.4 because guzzle does not support it
