mirror of
https://github.com/humhub/humhub.git
synced 2025-01-17 22:28:51 +01:00
995fc0f67d
Upgrade npm globally (Travis)
65 lines
1.6 KiB
YAML
65 lines
1.6 KiB
YAML
language: php
|
|
|
|
php:
|
|
- 5.6
|
|
- 7.0
|
|
- 7.1
|
|
- 7.2
|
|
|
|
matrix:
|
|
fast_finish: true
|
|
|
|
dist: trusty
|
|
|
|
sudo: required
|
|
addons:
|
|
chrome: stable
|
|
|
|
# cache vendor dirs
|
|
cache:
|
|
directories:
|
|
- $HOME/.composer/cache
|
|
|
|
services: mysql
|
|
|
|
before_install:
|
|
- wget https://chromedriver.storage.googleapis.com/2.40/chromedriver_linux64.zip
|
|
- unzip -d $HOME chromedriver_linux64.zip
|
|
- $HOME/chromedriver --url-base=/wd/hub &
|
|
- sudo curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
|
|
- sudo apt-get install -y nodejs
|
|
- npm install -g npm@latest
|
|
|
|
install:
|
|
# Run Composer update
|
|
- travis_retry composer self-update && composer --version
|
|
- travis_retry composer install --prefer-dist --no-interaction
|
|
- npm install
|
|
- grunt build-assets
|
|
- |
|
|
mysql -e 'CREATE DATABASE `humhub_test` CHARACTER SET utf8 COLLATE utf8_general_ci;'
|
|
cd $TRAVIS_BUILD_DIR/protected/humhub/tests
|
|
php codeception/bin/yii migrate/up --includeModuleMigrations=1 --interactive=0
|
|
php codeception/bin/yii installer/auto
|
|
php codeception/bin/yii search/rebuild
|
|
php ../../vendor/bin/codecept build
|
|
|
|
script:
|
|
- |
|
|
cd $TRAVIS_BUILD_DIR
|
|
php -S 127.0.0.1:8080 &> /dev/null &
|
|
- sleep 5
|
|
- curl --fail http://127.0.0.1:8080/index-test.php
|
|
- |
|
|
cd $TRAVIS_BUILD_DIR/protected/humhub/tests
|
|
php ../../vendor/bin/codecept run --env travis
|
|
after_failure:
|
|
#- cd ../modules/user/tests/codeception/_output/
|
|
#- ls
|
|
#- curl --upload-file ./user.acceptance.AccountCest.testBaseAccountSettings.fail.png https://transfer.sh/fail.png
|
|
#- cat user.acceptance.AccountCest.testBaseAccountSettings.fail.html
|
|
- cd ../../runtime/logs
|
|
- cat app.log
|
|
#- ls
|
|
|