Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 18 additions & 14 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ name: CI
on:
pull_request:
push:
branches: [ main ]
branches: [main]

jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up Ruby
uses: ruby/setup-ruby@v1
Expand All @@ -23,33 +23,37 @@ jobs:

test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
rails-version: ["rails-7-1", "rails-7-2", "rails-8-0"]

# services:
# redis:
# image: redis
# ports:
# - 6379:6379
# options: --health-cmd "redis-cli ping" --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- name: Install packages
run: sudo apt-get update && sudo apt-get install --no-install-recommends -y build-essential git libyaml-dev pkg-config google-chrome-stable
run: sudo apt-get update && sudo apt-get install --no-install-recommends -y build-essential git libyaml-dev pkg-config

- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ruby-3.4.5
bundler-cache: true
ruby-version: "3.3"
bundler-cache: false

- name: Install dependencies
run: bundle install

- name: Generate Appraisal gemfiles
run: bundle exec appraisal install

- name: Run tests
run: bundle exec rspec
run: bundle exec appraisal ${{ matrix.rails-version }} rspec

- name: Keep screenshots from failed system tests
uses: actions/upload-artifact@v4
if: failure()
with:
name: screenshots
name: screenshots-${{ matrix.rails-version }}
path: ${{ github.workspace }}/tmp/screenshots
if-no-files-found: ignore
16 changes: 16 additions & 0 deletions Appraisals
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Appraisals file for testing against multiple Rails versions

appraise "rails-7-1" do
gem "rails", "~> 7.1.0"
gem "activestorage", "~> 7.1.0"
end

appraise "rails-7-2" do
gem "rails", "~> 7.2.0"
gem "activestorage", "~> 7.2.0"
end

appraise "rails-8-0" do
gem "rails", "~> 8.0.0"
gem "activestorage", "~> 8.0.0"
end
51 changes: 40 additions & 11 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
PATH
remote: .
specs:
fileboost (0.1.5)
activestorage (>= 6.0)
fileboost (0.2.0.rc1)
activestorage (>= 7)

GEM
remote: https://rubygems.org/
Expand Down Expand Up @@ -78,6 +78,10 @@ GEM
securerandom (>= 0.3)
tzinfo (~> 2.0, >= 2.0.5)
uri (>= 0.13.1)
appraisal (2.5.0)
bundler
rake
thor (>= 0.14.0)
ast (2.4.3)
base64 (0.3.0)
benchmark (0.4.1)
Expand Down Expand Up @@ -129,10 +133,22 @@ GEM
net-smtp (0.5.1)
net-protocol
nio4r (2.7.4)
nokogiri (1.18.9-aarch64-linux-gnu)
racc (~> 1.4)
nokogiri (1.18.9-aarch64-linux-musl)
racc (~> 1.4)
nokogiri (1.18.9-arm-linux-gnu)
racc (~> 1.4)
nokogiri (1.18.9-arm-linux-musl)
racc (~> 1.4)
nokogiri (1.18.9-arm64-darwin)
racc (~> 1.4)
nokogiri (1.18.9-x86_64-darwin)
racc (~> 1.4)
nokogiri (1.18.9-x86_64-linux-gnu)
racc (~> 1.4)
nokogiri (1.18.9-x86_64-linux-musl)
racc (~> 1.4)
parallel (1.27.0)
parser (3.3.9.0)
ast (~> 2.4.1)
Expand All @@ -148,7 +164,7 @@ GEM
psych (5.2.6)
date
stringio
puma (7.0.1)
puma (7.0.2)
nio4r (~> 2.0)
racc (1.8.1)
rack (3.2.1)
Expand Down Expand Up @@ -247,16 +263,22 @@ GEM
rubocop-rails (>= 2.30)
ruby-progressbar (1.13.0)
securerandom (0.4.1)
sqlite3 (2.7.3-aarch64-linux-gnu)
sqlite3 (2.7.3-aarch64-linux-musl)
sqlite3 (2.7.3-arm-linux-gnu)
sqlite3 (2.7.3-arm-linux-musl)
sqlite3 (2.7.3-arm64-darwin)
sqlite3 (2.7.3-x86_64-darwin)
sqlite3 (2.7.3-x86_64-linux-gnu)
sqlite3 (2.7.3-x86_64-linux-musl)
stringio (3.1.7)
thor (1.4.0)
timeout (0.4.3)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unicode-display_width (3.1.5)
unicode-emoji (~> 4.0, >= 4.0.4)
unicode-emoji (4.0.4)
unicode-display_width (3.2.0)
unicode-emoji (~> 4.1)
unicode-emoji (4.1.0)
uri (1.0.3)
useragent (0.16.11)
websocket-driver (0.8.0)
Expand All @@ -266,21 +288,28 @@ GEM
zeitwerk (2.7.3)

PLATFORMS
aarch64-linux-gnu
aarch64-linux-musl
arm-linux-gnu
arm-linux-musl
arm64-darwin
x86_64-linux
x86_64-darwin
x86_64-linux-gnu
x86_64-linux-musl

DEPENDENCIES
bundler (~> 2)
appraisal (~> 2.5)
bundler (>= 2.1, < 2.7)
combustion (~> 1)
fileboost!
propshaft
puma
rails (~> 8.0.0)
rails (>= 7)
rake (~> 13.0)
rspec (~> 3.0)
rspec-rails (~> 6.0)
rubocop-rails-omakase
sqlite3 (~> 2.0, >= 0)
sqlite3

BUNDLED WITH
2.7.1
2.6.9
Loading