-
Notifications
You must be signed in to change notification settings - Fork 1
65 lines (58 loc) · 1.51 KB
/
Copy path_ruby-rspec.yml
File metadata and controls
65 lines (58 loc) · 1.51 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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
name: Ruby RSpec (shared)
on:
workflow_call:
inputs:
rspec-working-directory:
type: string
required: true
needs-server-gems:
type: boolean
required: false
default: true
setup-go:
type: boolean
required: false
default: false
jobs:
rspec:
name: RSpec (Ruby ${{ matrix.ruby }})
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: read
strategy:
fail-fast: false
matrix:
ruby:
- "3.2"
- "3.3"
- "3.4"
steps:
- name: Check out source
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Set up Ruby + Bundler cache (servers/ruby)
if: ${{ inputs.needs-server-gems }}
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
working-directory: servers/ruby
- name: Set up Ruby + Bundler cache
if: ${{ inputs.rspec-working-directory != 'servers/ruby' }}
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
working-directory: ${{ inputs.rspec-working-directory }}
- name: Set up Go
if: ${{ inputs.setup-go }}
uses: actions/setup-go@v6
with:
go-version: "stable"
- name: Run RSpec
working-directory: ${{ inputs.rspec-working-directory }}
shell: bash
run: |
bundle exec rspec