-
Notifications
You must be signed in to change notification settings - Fork 8
33 lines (30 loc) · 993 Bytes
/
ruby.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
name: Ruby
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
ruby: ['3.0.6', '3.1.4', '3.2.0']
steps:
- uses: actions/checkout@v2
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
- name: Build
run: |
gem install bundler
bundle install --jobs 4 --retry 3
- name: Run linter
run: bundle exec rubocop
- name: Run tests
run: bundle exec rake test
- run: 'echo "$GOOGLE_APPLICATION_CREDENTIALS" > account_secret.json'
shell: bash
env:
GOOGLE_APPLICATION_CREDENTIALS: ${{secrets.GOOGLE_APPLICATION_CREDENTIALS}}
- name: Run private google sheet tests
if: matrix.ruby == '3.2.0' # Limit execution on latest ruby version to prevent reaching rate limits
run: bundle exec rake test_private_google_sheet
env:
GOOGLE_APPLICATION_CREDENTIALS: 'account_secret.json'