mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
* php artisan serve and dusk testing * Fix style * move if into, in case we need to have different configs * fix travis yml * Add missing folders files * Try to fixup Travis-ci * revert variable, change check * skip browser tests for phpunit runs set up env correctly * maybe bg is needed * attempt to fix env * install Chrome * Update tests fix migrations * Move pylint to python2 * use testing .env * Running chrome on port 9515 conflicts with the instance started by the tests. It is probably not needed. * suppress some artisan serve output * remove the unused updater
54 lines
1.3 KiB
YAML
54 lines
1.3 KiB
YAML
sudo: required
|
|
language: php
|
|
addons:
|
|
chrome: stable
|
|
services:
|
|
- mysql
|
|
env:
|
|
global:
|
|
APP_ENV=testing
|
|
matrix:
|
|
fast_finish: true
|
|
include:
|
|
- php: 7.3
|
|
env: SKIP_STYLE_CHECK=1
|
|
- php: 7.2
|
|
env: SKIP_UNIT_CHECK=1 BROWSER_TEST=1
|
|
- php: 7.1
|
|
env: SKIP_STYLE_CHECK=1 EXECUTE_BUILD_DOCS=true
|
|
|
|
cache:
|
|
directories:
|
|
- vendor
|
|
- $HOME/.cache/pip
|
|
- $HOME/.composer/cache
|
|
|
|
before_install:
|
|
- sudo apt-get -qq update
|
|
- sudo apt-get install -y snmp fping python3-pip
|
|
- mysql -e 'CREATE DATABASE librenms_phpunit_78hunjuybybh CHARACTER SET utf8 COLLATE utf8_unicode_ci;'
|
|
- cp tests/config/config.test.php config.php
|
|
|
|
install:
|
|
- travis_retry composer install --no-interaction --prefer-dist --no-suggest
|
|
- pip3 install --user snmpsim
|
|
- pip install --user mysql-python pylint
|
|
|
|
after_failure:
|
|
- tail /tmp/snmpsimd.log
|
|
|
|
before_script:
|
|
- test -z "$BROWSER_TEST" || php artisan serve --env=dusk.testing 2>/dev/null &
|
|
|
|
script:
|
|
- set -e
|
|
- export FILES=$(git diff --diff-filter=d --name-only master | tr '\n' ' '|sed 's/,*$//g')
|
|
- php scripts/pre-commit.php -q -l
|
|
- php scripts/pre-commit.php -q -s
|
|
- php scripts/pre-commit.php -u --db --snmpsim --fail-fast
|
|
- test -z "$BROWSER_TEST" || php artisan dusk
|
|
- bash -n daily.sh
|
|
- pylint -E poller-wrapper.py discovery-wrapper.py
|
|
- bash scripts/deploy-docs.sh
|
|
- set +e
|