Skip to content

Commit

Permalink
Merge pull request #1539 from S-H-GAMELINKS/use-flatware-and-fix-redi…
Browse files Browse the repository at this point in the history
…s-setting

Fix Redis setting for test and Use flatware
  • Loading branch information
S-H-GAMELINKS authored Oct 26, 2024
2 parents 5e19f22 + c868978 commit 8dac38a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/test-ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ jobs:
rspec-persistence-main
rspec-persistence
- run: bin/rspec
- run: bin/flatware rspec -r ./spec/flatware_helper.rb

- name: Upload coverage reports to Codecov
if: matrix.ruby-version == '.ruby-version'
Expand Down
2 changes: 2 additions & 0 deletions lib/mastodon/redis_configuration.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ def setup_config(prefix: nil, defaults: {})
port = ENV.fetch("#{prefix}PORT", defaults[:port])
db = ENV.fetch("#{prefix}DB", defaults[:db])

db = ENV.fetch('TEST_ENV_NUMBER', nil) if Rails.env.test?

return { url:, driver: } if url

sentinel_options = setup_sentinels(prefix, default_user: user, default_password: password)
Expand Down

0 comments on commit 8dac38a

Please sign in to comment.