spec/mongoid/criteria/marshalable_spec.rb in mongoid-8.1.7 vs spec/mongoid/criteria/marshalable_spec.rb in mongoid-9.0.0

- old
+ new

@@ -1,6 +1,7 @@ # frozen_string_literal: true +# rubocop:todo all require "spec_helper" describe Mongoid::Criteria::Marshalable do describe "Marshal.dump" do @@ -28,11 +29,11 @@ context "when it receives driver mongo1x" do let(:dump) { Marshal.dump(criteria) } before do - expect_any_instance_of(Mongoid::Criteria).to receive(:marshal_dump).and_wrap_original do |m, *args| - data = m.call(*args) + expect_any_instance_of(Mongoid::Criteria).to receive(:marshal_dump).and_wrap_original do |m, *args, **kwargs| + data = m.call(*args, **kwargs) data[1] = :mongo1x data end end