-
Notifications
You must be signed in to change notification settings - Fork 3
59 lines (49 loc) · 1.29 KB
/
main.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
55
56
57
58
59
name: CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./rails_root
steps:
- uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- name: Install dependencies
run: |
gem install bundler
bundle install --jobs 4 --retry 3
- name: Run RSpec tests
if: '!cancelled()'
run: |
bundle exec rspec
- name: Run Cucumber tests
if: '!cancelled()'
run: |
bundle exec cucumber
- name: Generate SimpleCov report
if: '!cancelled()'
run: |
COVERAGE=true bundle exec rspec
COVERAGE=true bundle exec cucumber
# - name: Upload coverage report
# if: '!cancelled()'
# uses: actions/upload-artifact@v2
# with:
# name: coverage
# path: coverage
- name: Upload coverage report to CodeClimate
if: '!cancelled()'
uses: paambaati/[email protected]
env:
CC_TEST_REPORTER_ID: c65072aca2cabde6c5f61913e0a45910a273d78e1a309c785a64de223b1c21af
with:
coverageLocations: ${{ github.workspace }}/**/coverage.json:simplecov
debug: true