Skip to content

Commit 0929173

Browse files
yahondaclaude
andcommitted
Register oracle_enhanced adapter for ActiveRecord 8.0 in specs
ActiveRecord 8.0 requires adapters to be explicitly registered. The oracle_enhanced adapter only auto-registers via Railtie when Rails is present. Register it manually in spec_helper.rb. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent ead4714 commit 0929173

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

spec/spec_helper.rb

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,14 @@
2020

2121
unless ENV["NO_ACTIVERECORD"]
2222
require "active_record"
23+
require "active_record/connection_adapters/oracle_enhanced_adapter"
24+
if ActiveRecord::ConnectionAdapters.respond_to?(:register)
25+
ActiveRecord::ConnectionAdapters.register(
26+
"oracle_enhanced",
27+
"ActiveRecord::ConnectionAdapters::OracleEnhancedAdapter",
28+
"active_record/connection_adapters/oracle_enhanced_adapter"
29+
)
30+
end
2331
else
2432
puts "Without ActiveRecord"
2533
end

0 commit comments

Comments
 (0)