forked from forem/forem
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
54 lines (54 loc) · 2.05 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
50
51
52
53
54
sudo: required
language: ruby
cache:
directories:
- vendor/bundle
- node_modules
rvm:
- 2.5.1
addons:
postgresql: '9.6'
chrome: stable
env:
global:
- RAILS_ENV=test
- CC_TEST_REPORTER_ID=f39e060a8b1a558ebd8aff75d5b9760bf1ae98f3f85d628ae28814f3c66438cd
branches:
only:
- master
install:
- bundle install --path vendor/bundle
- bundle exec chromedriver-update
- yarn install
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64
> ./cc-test-reporter
- chmod +x ./cc-test-reporter
before_script:
- cp config/database.yml.travis config/database.yml
- psql -c 'create database travis_ci_test;' -U postgres
script:
- bundle exec rails webpacker:compile
- bundle exec rake db:schema:load
- "./cc-test-reporter before-build"
- bundle exec rspec spec
- "./cc-test-reporter format-coverage -t simplecov -o coverage/codeclimate.simplecov.json"
- yarn test
- "./cc-test-reporter format-coverage -t lcov -o coverage/codeclimate.lcov.json"
- "./cc-test-reporter sum-coverage coverage/codeclimate.*.json"
- "./cc-test-reporter upload-coverage"
- bundle exec bundle-audit update && bundle exec bundle-audit check
deploy:
provider: heroku
api_key: "$HEROKU_AUTH_TOKEN"
app:
master: practicaldev
run:
- rake db:migrate
after_deploy:
- bash after_deploy.sh
notifications:
slack:
on_pull_requests: false
on_success: always
rooms:
secure: Ua+907nWEUQl9y8xiyT1vP6usbZEfNinZHjrxricJybbOJsLtD8ShKdiXiCOY3xlrOzxVb/2DSTjIhX7Bf1j2QYy6UW+Ff20ZyFlMl/cDizEpk15R4YyOwM6+umWtQXvDklnyDlVzg5PuvCK8Gsjg9t2lwsxd5b0muHktggJnP7e0m3iEslPAyNuLAbTFwRpMZnuiKb8kUowzuIoQJ0Y8eNPCa8LedlVagS2G2Jz0rxCTIT5O+cfM7ru0vmg8abO7owIsyc7C/frilCYGqile1nQyvWwiR6n6r63dmS839HXzPBvhSWO2WhHPnOVBeovYGOUkVHgqLPwsfSeDJZWLCpO+FcN2jW8f1u0+JcnJuX7rxIGIJzMZrlk9A4N9QI6hZhNinaNKfbQCUyc8ITwDTfh9fKL0tqrbzfUgBFuEXf6V71u64HheDcQzwlC4ZQKCtEyXO+iPAZphQO47bJ99O3ubtMuu0cY9lKz0rp5c5iGOnioGi+5cleaAWt6cDO5A0PyFas+/4Hz7CghqJxeTcyZ3rqF2vGAL9xcKuuD/3KRns3MQx4oZcjVVUz1ep4ZY/B0P943fxDsJ5h2jgAJ2UXfNIqbeP5ZNmJFG/fbN0UIEUwl6Fmlo3mGoBOBdNFo0E4VdtiGM00KxFCgxxILmYEjb5ngDKwJprNhnrSyUU4=