-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (40 loc) · 1.2 KB
/
ruby-tests.yml
File metadata and controls
45 lines (40 loc) · 1.2 KB
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
name: Ruby Tests
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
name: Specs - Ruby ${{ matrix.ruby-version }} ${{matrix.gemfile}}
runs-on: ubuntu-latest
env:
CC_TEST_REPORTER_ID: 5e30c12a37d6500cfc4d084d0caafc530c404cbc3782c36207f420c3de1321ac
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.gemfile }}.gemfile
COVERAGE: true
strategy:
matrix:
gemfile:
- activerecord6
- activerecord70
- activerecord71
ruby-version:
- "3.3"
- "3.2"
- "3.1"
steps:
- uses: actions/checkout@v2
- name: Set up Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
- name: Install dependencies
run: bundle install
- name: Run rubocop
run: bundle exec rubocop
if: matrix.ruby-version == '3.3' && matrix.gemfile == 'activerecord71'
- name: Run tests
run: bundle exec rspec
- name: Upload Coverage
uses: paambaati/codeclimate-action@v3.0.0
if: matrix.ruby-version == '3.3' && matrix.gemfile == 'activerecord71'