Skip to content

Commit 3f6c9b6

Browse files
authored
Merge pull request #11 from open-feature/feat/improve-github-actions
build: Improve github actions
2 parents 90e2b17 + 96f8b1d commit 3f6c9b6

File tree

2 files changed

+57
-7
lines changed

2 files changed

+57
-7
lines changed

.github/workflows/main.yml

Lines changed: 54 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,25 +8,72 @@ on:
88

99
jobs:
1010
build:
11-
runs-on: ubuntu-latest
11+
runs-on: ${{ matrix.os }}
1212
name: Ruby ${{ matrix.ruby }}
1313
strategy:
14+
fail-fast: false
1415
matrix:
16+
os: [ubuntu-latest, macos-latest, windows-latest]
1517
ruby:
1618
- "3.1.2"
1719
- "2.7.6"
1820
- "3.0.4"
21+
env:
22+
BUNDLE_GEMFILE: Gemfile
1923

2024
steps:
2125
- uses: actions/checkout@v3
22-
- name: Set up Ruby
26+
- uses: ruby/setup-ruby@v1
27+
with:
28+
ruby-version: ${{ matrix.ruby }}
29+
bundler-cache: true
30+
- run: bundle install
31+
- run: bundle exec rake
32+
33+
rubocop:
34+
runs-on: ${{ matrix.os }}
35+
name: Rubocop ${{ matrix.ruby }}
36+
strategy:
37+
fail-fast: false
38+
matrix:
39+
os: [ubuntu-latest, macos-latest, windows-latest]
40+
ruby:
41+
- "3.1.2"
42+
- "2.7.6"
43+
- "3.0.4"
44+
env:
45+
BUNDLE_GEMFILE: Gemfile
46+
47+
steps:
48+
- uses: actions/checkout@v3
49+
- name: Set up Ruby ${{ matrix.ruby }}
2350
uses: ruby/setup-ruby@v1
2451
with:
2552
ruby-version: ${{ matrix.ruby }}
2653
bundler-cache: true
27-
- name: Install dependencies
28-
run: bundle install
29-
- name: Run the default task
30-
run: bundle exec rake
31-
- name: Rubocop
54+
- name: Run style checks
3255
run: bundle exec rubocop
56+
57+
test:
58+
runs-on: ${{ matrix.os }}
59+
name: RSpec ${{ matrix.ruby }}
60+
strategy:
61+
fail-fast: false
62+
matrix:
63+
os: [ubuntu-latest, macos-latest, windows-latest]
64+
ruby:
65+
- "3.1.2"
66+
- "2.7.6"
67+
- "3.0.4"
68+
env:
69+
BUNDLE_GEMFILE: Gemfile
70+
71+
steps:
72+
- uses: actions/checkout@v3
73+
- name: Set up Ruby ${{ matrix.ruby }}
74+
uses: ruby/setup-ruby@v1
75+
with:
76+
ruby-version: ${{ matrix.ruby }}
77+
bundler-cache: true
78+
- name: Run tests
79+
run: bundle exec rspec

Gemfile.lock

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,9 @@ GEM
4747
PLATFORMS
4848
arm64-darwin-21
4949
arm64-darwin-22
50+
x64-mingw-ucrt
51+
x64-mingw32
52+
x86_64-darwin-19
5053
x86_64-darwin-21
5154
x86_64-darwin-22
5255
x86_64-linux

0 commit comments

Comments
 (0)