Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix CI [ part 2 ] #645

Merged
merged 3 commits into from
Aug 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
11 changes: 7 additions & 4 deletions .github/workflows/rspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,31 +8,34 @@ on:
branches:
- master

permissions:
contents: read

jobs:
test:
name: Ruby ${{ matrix.ruby }} - Gemfile ${{ matrix.gemfile }}
name: Ruby ${{ matrix.ruby }} - ${{ matrix.rails }}
runs-on: ubuntu-latest

strategy:
matrix:
ruby: [3.1, 3.2, 3.3]
gemfile:
rails:
- rails_7.0
- rails_7.1
- rails_7.2
- rails_edge
env:
RAILS_ENV: test
DISPLAY: ":99.0"
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.rails }}.gemfile
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice


steps:
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
env:
BUNDLE_GEMFILE: gemfiles/${{ matrix.rails }}.gemfile

- name: Set up PhantomJS
run: |
Expand Down
2 changes: 2 additions & 0 deletions best_in_place.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ DESC
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
s.require_paths = ["lib"]

s.required_ruby_version = '>= 3.1.0'

s.add_runtime_dependency 'actionpack', '>= 7.0'
s.add_runtime_dependency 'railties', '>= 7.0'
end
4 changes: 2 additions & 2 deletions lib/best_in_place/engine.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
module BestInPlace
class Engine < Rails::Engine
initializer 'best_in_place' do
ActionView::Base.send(:include, BestInPlace::Helper)
ActionController::Base.send(:include, BestInPlace::ControllerExtensions)
ActiveSupport.on_load(:action_view) { include BestInPlace::Helper }
ActiveSupport.on_load(:action_controller_base) { include BestInPlace::ControllerExtensions }
end
end
end
2 changes: 1 addition & 1 deletion lib/best_in_place/railtie.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
module BestInPlace
class Railtie < ::Rails::Railtie #:nodoc:
config.after_initialize do
BestInPlace::ViewHelpers = ActionView::Base.new({}, {}, "")
BestInPlace::ViewHelpers = ActionView::Base.empty
end
end
end