Skip to content

Commit

Permalink
Update main Gemfile to Rails 7.2 and add test. (#20)
Browse files Browse the repository at this point in the history
* Removed Rails 5.2, 6.0 test
  • Loading branch information
huacnlee authored Sep 24, 2024
1 parent 99d8726 commit 5b74fb8
Show file tree
Hide file tree
Showing 9 changed files with 167 additions and 125 deletions.
35 changes: 19 additions & 16 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,43 +4,46 @@ jobs:
build:
if: "!contains(github.event.head_commit.message, '[skip ci]')"
runs-on: ubuntu-latest
services:
postgres:
image: postgres:15
env:
POSTGRES_DB: action-store-test
POSTGRES_USER: "postgres"
POSTGRES_PASSWORD: "123456"
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
strategy:
fail-fast: false
matrix:
include:
- ruby: 3.2
- ruby: 3.3
gemfile: Gemfile
postgres: 10
rails_version: 7.2
- ruby: 3.2
gemfile: gemfiles/Gemfile-7-1
rails_version: 7.1
- ruby: 3.2
gemfile: gemfiles/Gemfile-7-0
postgres: 10
rails_version: 7.0
- ruby: 2.7
gemfile: gemfiles/Gemfile-6-1
postgres: 10
rails_version: 6.1
- ruby: 2.6
gemfile: gemfiles/Gemfile-6-0
postgres: 10
rails_version: 6.0
- ruby: 2.6
gemfile: gemfiles/Gemfile-5-2
postgres: 10
rails_version: 5.0

env:
BUNDLE_GEMFILE: ${{ matrix.gemfile }}
USE_OFFICIAL_GEM_SOURCE: 1
RAILS_VERSION: ${{ matrix.rails_version }}
DATABASE_URL: postgres://postgres:123456@localhost:5432/action-store-test
steps:
- uses: actions/checkout@v2
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
- uses: ankane/setup-postgres@v1
with:
postgres-version: ${{ matrix.postgres }}
- run: createdb action-store-test
- run: bundle exec rails test
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
/test/version_tmp/
/tmp/
test/dummy/log/**/*
test/dummy/tmp/**/*

# Used by dotenv library to load environment variables.
# .env
Expand Down
26 changes: 26 additions & 0 deletions DEVELOPMENT
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# DEVELOPMENT GUIDE

```bash
docker-compose up -d
```

Create local datebase

```bash
bundle install
rails db:create db:migrate
```

Run tests

```bash
rails test
```

## Publish new RubyGem version

- Update version in `lib/action_store/version.rb`
- Run `bundle install`.
- Create a new tag in the format `vX.X.X` and push it to the repository.
- Run `rake release` to publish the new version to RubyGems.
- Write release notes in GitHub releases: https://github.com/rails-engine/action-store/releases
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
source "https://rubygems.org"

gemspec
gem "rails", "~> 7.1.0"
gem "rails", "~> 7.2.0"
201 changes: 99 additions & 102 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,182 +7,179 @@ PATH
GEM
remote: https://rubygems.org/
specs:
actioncable (7.1.1)
actionpack (= 7.1.1)
activesupport (= 7.1.1)
actioncable (7.2.1)
actionpack (= 7.2.1)
activesupport (= 7.2.1)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
zeitwerk (~> 2.6)
actionmailbox (7.1.1)
actionpack (= 7.1.1)
activejob (= 7.1.1)
activerecord (= 7.1.1)
activestorage (= 7.1.1)
activesupport (= 7.1.1)
mail (>= 2.7.1)
net-imap
net-pop
net-smtp
actionmailer (7.1.1)
actionpack (= 7.1.1)
actionview (= 7.1.1)
activejob (= 7.1.1)
activesupport (= 7.1.1)
mail (~> 2.5, >= 2.5.4)
net-imap
net-pop
net-smtp
actionmailbox (7.2.1)
actionpack (= 7.2.1)
activejob (= 7.2.1)
activerecord (= 7.2.1)
activestorage (= 7.2.1)
activesupport (= 7.2.1)
mail (>= 2.8.0)
actionmailer (7.2.1)
actionpack (= 7.2.1)
actionview (= 7.2.1)
activejob (= 7.2.1)
activesupport (= 7.2.1)
mail (>= 2.8.0)
rails-dom-testing (~> 2.2)
actionpack (7.1.1)
actionview (= 7.1.1)
activesupport (= 7.1.1)
actionpack (7.2.1)
actionview (= 7.2.1)
activesupport (= 7.2.1)
nokogiri (>= 1.8.5)
rack (>= 2.2.4)
racc
rack (>= 2.2.4, < 3.2)
rack-session (>= 1.0.1)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
actiontext (7.1.1)
actionpack (= 7.1.1)
activerecord (= 7.1.1)
activestorage (= 7.1.1)
activesupport (= 7.1.1)
useragent (~> 0.16)
actiontext (7.2.1)
actionpack (= 7.2.1)
activerecord (= 7.2.1)
activestorage (= 7.2.1)
activesupport (= 7.2.1)
globalid (>= 0.6.0)
nokogiri (>= 1.8.5)
actionview (7.1.1)
activesupport (= 7.1.1)
actionview (7.2.1)
activesupport (= 7.2.1)
builder (~> 3.1)
erubi (~> 1.11)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
activejob (7.1.1)
activesupport (= 7.1.1)
activejob (7.2.1)
activesupport (= 7.2.1)
globalid (>= 0.3.6)
activemodel (7.1.1)
activesupport (= 7.1.1)
activerecord (7.1.1)
activemodel (= 7.1.1)
activesupport (= 7.1.1)
activemodel (7.2.1)
activesupport (= 7.2.1)
activerecord (7.2.1)
activemodel (= 7.2.1)
activesupport (= 7.2.1)
timeout (>= 0.4.0)
activestorage (7.1.1)
actionpack (= 7.1.1)
activejob (= 7.1.1)
activerecord (= 7.1.1)
activesupport (= 7.1.1)
activestorage (7.2.1)
actionpack (= 7.2.1)
activejob (= 7.2.1)
activerecord (= 7.2.1)
activesupport (= 7.2.1)
marcel (~> 1.0)
activesupport (7.1.1)
activesupport (7.2.1)
base64
bigdecimal
concurrent-ruby (~> 1.0, >= 1.0.2)
concurrent-ruby (~> 1.0, >= 1.3.1)
connection_pool (>= 2.2.5)
drb
i18n (>= 1.6, < 2)
logger (>= 1.4.2)
minitest (>= 5.1)
mutex_m
tzinfo (~> 2.0)
base64 (0.1.1)
bigdecimal (3.1.4)
builder (3.2.4)
concurrent-ruby (1.2.2)
securerandom (>= 0.3)
tzinfo (~> 2.0, >= 2.0.5)
base64 (0.2.0)
bigdecimal (3.1.8)
builder (3.3.0)
concurrent-ruby (1.3.4)
connection_pool (2.4.1)
crass (1.0.6)
date (3.3.3)
drb (2.1.1)
ruby2_keywords
erubi (1.12.0)
date (3.3.4)
drb (2.2.1)
erubi (1.13.0)
factory_bot (6.2.0)
activesupport (>= 5.0.0)
globalid (1.2.1)
activesupport (>= 6.1)
i18n (1.14.1)
i18n (1.14.6)
concurrent-ruby (~> 1.0)
io-console (0.6.0)
irb (1.8.1)
rdoc
reline (>= 0.3.8)
loofah (2.21.4)
io-console (0.7.2)
irb (1.14.0)
rdoc (>= 4.0.0)
reline (>= 0.4.2)
logger (1.6.1)
loofah (2.22.0)
crass (~> 1.0.2)
nokogiri (>= 1.12.0)
mail (2.8.1)
mini_mime (>= 0.1.1)
net-imap
net-pop
net-smtp
marcel (1.0.2)
marcel (1.0.4)
mini_mime (1.1.5)
mini_portile2 (2.8.4)
minitest (5.20.0)
mutex_m (0.1.2)
net-imap (0.4.1)
mini_portile2 (2.8.7)
minitest (5.25.1)
net-imap (0.4.16)
date
net-protocol
net-pop (0.1.2)
net-protocol
net-protocol (0.2.1)
net-protocol (0.2.2)
timeout
net-smtp (0.4.0)
net-smtp (0.5.0)
net-protocol
nio4r (2.5.9)
nokogiri (1.15.4)
nio4r (2.7.3)
nokogiri (1.16.7)
mini_portile2 (~> 2.8.2)
racc (~> 1.4)
pg (1.5.4)
psych (5.1.1)
psych (5.1.2)
stringio
racc (1.7.1)
rack (3.0.8)
racc (1.8.1)
rack (3.1.7)
rack-session (2.0.0)
rack (>= 3.0.0)
rack-test (2.1.0)
rack (>= 1.3)
rackup (2.1.0)
rack (>= 3)
webrick (~> 1.8)
rails (7.1.1)
actioncable (= 7.1.1)
actionmailbox (= 7.1.1)
actionmailer (= 7.1.1)
actionpack (= 7.1.1)
actiontext (= 7.1.1)
actionview (= 7.1.1)
activejob (= 7.1.1)
activemodel (= 7.1.1)
activerecord (= 7.1.1)
activestorage (= 7.1.1)
activesupport (= 7.1.1)
rails (7.2.1)
actioncable (= 7.2.1)
actionmailbox (= 7.2.1)
actionmailer (= 7.2.1)
actionpack (= 7.2.1)
actiontext (= 7.2.1)
actionview (= 7.2.1)
activejob (= 7.2.1)
activemodel (= 7.2.1)
activerecord (= 7.2.1)
activestorage (= 7.2.1)
activesupport (= 7.2.1)
bundler (>= 1.15.0)
railties (= 7.1.1)
railties (= 7.2.1)
rails-dom-testing (2.2.0)
activesupport (>= 5.0.0)
minitest
nokogiri (>= 1.6)
rails-html-sanitizer (1.6.0)
loofah (~> 2.21)
nokogiri (~> 1.14)
railties (7.1.1)
actionpack (= 7.1.1)
activesupport (= 7.1.1)
irb
railties (7.2.1)
actionpack (= 7.2.1)
activesupport (= 7.2.1)
irb (~> 1.13)
rackup (>= 1.0.0)
rake (>= 12.2)
thor (~> 1.0, >= 1.2.2)
zeitwerk (~> 2.6)
rake (13.0.6)
rdoc (6.5.0)
rake (13.2.1)
rdoc (6.7.0)
psych (>= 4.0.0)
reline (0.3.9)
reline (0.5.10)
io-console (~> 0.5)
ruby2_keywords (0.0.5)
stringio (3.0.8)
thor (1.2.2)
timeout (0.4.0)
securerandom (0.3.1)
stringio (3.1.1)
thor (1.3.2)
timeout (0.4.1)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
useragent (0.16.10)
webrick (1.8.1)
websocket-driver (0.7.6)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.5)
zeitwerk (2.6.12)
zeitwerk (2.6.18)

PLATFORMS
ruby
Expand All @@ -191,7 +188,7 @@ DEPENDENCIES
action-store!
factory_bot
pg
rails (~> 7.1.0)
rails (~> 7.2.0)

BUNDLED WITH
2.2.3
2.5.3
Loading

0 comments on commit 5b74fb8

Please sign in to comment.