-
Notifications
You must be signed in to change notification settings - Fork 1
45 lines (43 loc) · 1.18 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
name: Test
on: [push]
jobs:
test:
strategy:
matrix:
ruby-version:
- "3.1"
- "3.2"
- "3.3"
gemfile:
- "rails-7-0"
runs-on: ubuntu-latest
env:
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/Gemfile-${{ matrix.gemfile }}
steps:
- uses: actions/checkout@v4
- name: Install dependencies from apt
run: |
sudo apt-get update
sudo apt-get install -y libvips42
- name: Set up Ruby ${{ matrix.ruby-version }}
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
bundler-cache: true
- uses: actions/setup-node@v4
with:
node-version: "18.x"
cache: "yarn"
- name: Install JS/TS Dependencies
run: yarn install
- name: Lint JS/TS
run: yarn lint
- name: Build JS/TS
run: yarn build
- name: Lint Ruby
run: bundle exec rubocop -c .rubocop.yml
- name: Ruby Tests
run: (cd spec/rails_app && bin/rails assets:precompile) && bin/rspec --format documentation
env:
RAILS_ENV: test
RSPEC_RETRY_RETRY_COUNT: 3