Skip to content

Commit 458fb20

Browse files
authoredJun 13, 2021
Use Zeitwerk for loading components (#634)
[changelog] added: - "Backward-compatibility extension that you can load via `require "rom/compat"` (via #634 refs #607) (@solnic)" changed: - "[BREAKING] `Setup#auto_registration` was renamed to `Setup#auto_register`. You can restore the original method via rom/compat extension (via #634 refs #607) (@solnic)" - "[internal] auto registration is now powered by Zeitwerk (via #634 refs #607) (@solnic)"
1 parent 6f3c47a commit 458fb20

File tree

57 files changed

+586
-53
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+586
-53
lines changed
 

‎Gemfile

+2
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ gem "rom-sql", github: "rom-rb/rom-sql", branch: "master"
1919
gem "dry-monitor", github: "dry-rb/dry-monitor", branch: "master"
2020
gem "dry-events", github: "dry-rb/dry-events", branch: "master"
2121

22+
gem "zeitwerk", github: "fxn/zeitwerk", branch: "main"
23+
2224
group :sql do
2325
gem "jdbc-postgres", platforms: :jruby
2426
gem "jdbc-sqlite3", platforms: :jruby

‎Rakefile

+11-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,15 @@ require "bundler/gem_tasks"
55
require "rspec/core"
66
require "rspec/core/rake_task"
77

8-
RSpec::Core::RakeTask.new(:spec)
8+
RSpec::Core::RakeTask.new("spec:all") do |t|
9+
t.pattern = ["spec/unit/**/*_spec.rb", "spec/integration/**/*_spec.rb"]
10+
end
11+
12+
RSpec::Core::RakeTask.new("spec:compat") do |t|
13+
t.pattern = ["spec/compat/**/*_spec.rb"]
14+
end
15+
16+
task "spec" => ["spec:all", "spec:compat"]
917

1018
task default: :spec
1119

@@ -25,8 +33,10 @@ namespace :benchmark do
2533
end
2634
end
2735

36+
# rubocop:disable Lint/SuppressedException
2837
begin
2938
require "yard-junk/rake"
3039
YardJunk::Rake.define_task(:text)
3140
rescue LoadError
3241
end
42+
# rubocop:enable Lint/SuppressedException

0 commit comments

Comments
 (0)
Please sign in to comment.