-
Notifications
You must be signed in to change notification settings - Fork 473
/
.travis.yml
49 lines (49 loc) · 1.17 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
sudo: false
branches:
except:
- gh-pages
language: php
php:
- 7.1.3 # 必须构建最低要求版本
- 7.1
- 7.2
- 7.3
env:
# - DB=mysql
- DB=postgres
services:
# - mysql
- postgresql
cache:
directories:
- $HOME/.composer/cache
before_install:
# Check and create database.
- sh -c "if [ '$DB' = 'postgres' ]; then psql -c 'create database plus;' -U postgres; echo $DB; fi"
- sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'CREATE DATABASE IF NOT EXISTS plus;'; echo $DB; fi"
- php ./scripts/travis-ci-settings.php $DB
install:
- composer install
- php artisan app:key-generate
- php artisan migrate -vvv
- php artisan db:seed -vvv
- php artisan vendor:publish --all -vvv
script: php vendor/bin/phpunit --coverage-clover=coverage.xml
after_script:
- php vendor/bin/codacycoverage clover coverage.xml
- bash <(curl -s https://codecov.io/bash)
jobs:
include:
- stage: Build
name: Build Assets Test
language: node_js
node_js: 10
cache:
directories:
- "node_modules"
services: null
env: null
before_install: null
install: npm install
script: npm run dev
after_script: null