-
Notifications
You must be signed in to change notification settings - Fork 15
53 lines (41 loc) · 1.2 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
44
45
46
47
48
49
50
51
52
53
name: Test
on:
push:
branches:
- "*"
pull_request:
branches:
- master
jobs:
test:
name: Test
runs-on: ubuntu-latest
timeout-minutes: 15
strategy:
fail-fast: false
matrix:
ruby-version: [2.3, 2.4, 2.5, 2.6, 2.7, 3.0, 3.1, 3.2, 3.3]
steps:
- name: Cancel previous runs
uses: styfle/cancel-workflow-action@0.12.1
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v4
- name: Set up Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
bundler: 1
- uses: actions/cache@v4
with:
path: vendor/bundle
key: ${{ runner.os }}-bundle-${{ matrix.ruby-version }}-v3-${{ hashFiles('rails-data-migrations.gemspec', 'Appraisals') }}
restore-keys: |
${{ runner.os }}-bundle-${{ matrix.ruby-version }}-v3-
- name: Install dependencies
run: |
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
bundle exec appraisal install --path vendor/bundle
- name: Run tests
run: bundle exec appraisal rake