-
Notifications
You must be signed in to change notification settings - Fork 1
44 lines (39 loc) · 1.09 KB
/
test.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
name: Ruby
on: [push]
env:
RAILS_ENV: test
jobs:
build:
if: true
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Set up Ruby 2.6
uses: actions/setup-ruby@v1
with:
ruby-version: 2.6.x
- name: cache gems
id: cache-gems
uses: actions/cache@v1
with:
path: vendor/bundle
key: ${{ runner.os }}--${{ hashFiles('Gemfile.lock') }}
- name: bundle install
run: |
gem install bundler
bundle install --jobs 4 --retry 3 --path=vendor/bundle --without production
- name: run rspec
run: |
# TODO
# tty-screen has some problem in mock testing
# @see https://ask.csdn.net/questions/1605370
# bundle exec rspec \
# --format progress \
# --tag ~slow \
# --profile \
# -- spec/
- name: Archive code coverage results
uses: actions/upload-artifact@v2
with:
name: code-coverage-report
path: tmp/test/code-coverage.html