2019-03-11 19:46:48 +03:00
|
|
|
dist: xenial
|
2013-05-13 00:15:35 +04:00
|
|
|
language: node_js
|
|
|
|
node_js:
|
2019-06-18 00:44:23 +03:00
|
|
|
- '12'
|
2019-03-12 00:41:55 +03:00
|
|
|
- '10'
|
|
|
|
- '8'
|
2019-03-11 19:46:48 +03:00
|
|
|
cache: yarn
|
|
|
|
services:
|
2019-03-12 00:41:55 +03:00
|
|
|
- mysql
|
2019-04-18 15:35:41 +03:00
|
|
|
# Don't run builds for renovate PRs
|
|
|
|
if: NOT head_branch =~ ^renovate
|
2020-02-03 15:41:41 +03:00
|
|
|
branches:
|
|
|
|
only:
|
|
|
|
- master
|
|
|
|
- 2.x
|
2013-10-30 00:54:37 +04:00
|
|
|
env:
|
2015-01-07 23:44:14 +03:00
|
|
|
matrix:
|
2019-03-12 00:41:55 +03:00
|
|
|
- DB=sqlite3 NODE_ENV=testing
|
|
|
|
- DB=mysql NODE_ENV=testing-mysql
|
2017-01-23 18:32:49 +03:00
|
|
|
install:
|
2019-11-06 05:37:28 +03:00
|
|
|
- yarn
|
2019-03-11 19:46:48 +03:00
|
|
|
before_script:
|
2019-03-12 00:41:55 +03:00
|
|
|
- if [ $DB == "mysql" ]; then mysql -e 'create database ghost_testing'; fi
|
2019-11-06 05:37:28 +03:00
|
|
|
- if [ "$DB" == "sqlite3" ]; then yarn add --force sqlite3; fi
|
2019-01-22 20:31:07 +03:00
|
|
|
script: |
|
2020-01-29 19:46:11 +03:00
|
|
|
if [[ "$TRAVIS_PULL_REQUEST_BRANCH" =~ ^renovate || "$TRAVIS_EVENT_TYPE" == "cron" ]]; then
|
2019-03-11 18:43:47 +03:00
|
|
|
yarn ci:regression
|
2019-01-22 20:31:07 +03:00
|
|
|
else
|
2019-03-11 18:43:47 +03:00
|
|
|
yarn ci
|
2019-01-22 20:31:07 +03:00
|
|
|
fi
|
2019-10-05 07:33:29 +03:00
|
|
|
notifications:
|
|
|
|
slack:
|
|
|
|
if: type = cron
|
|
|
|
rooms:
|
|
|
|
- secure: KzvGpf6RFHgQ3BkppKM4OejFjJYxH60KkDDShet0a0v+j/03HF5Nx0S0Vl9O/F2dPt2qWvblKb3j9EKgB7RsoFSdZuOk7ijA9Duvn+p9RrLom0C9JxOA3ob065WAGyE0OGRm1P5H98loX/L+6oOHC4/qqGKXgz6gUdBtZBn/yo8=
|
|
|
|
on_success: change
|
|
|
|
on_failure: always
|
|
|
|
on_pull_requests: false
|