We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b6dbe51 commit e9cee86Copy full SHA for e9cee86
lib/rspec/rails/matchers/relation_match_array.rb
@@ -1,3 +1,3 @@
1
-if defined?(ActiveRecord::Relation)
+if defined?(ActiveRecord::Relation) && defined?(RSpec::Matchers::BuiltIn::OperatorMatcher) # RSpec 4 removed OperatorMatcher
2
RSpec::Matchers::BuiltIn::OperatorMatcher.register(ActiveRecord::Relation, '=~', RSpec::Matchers::BuiltIn::ContainExactly)
3
end
0 commit comments