spec/elasticsearch/model/indexing_spec.rb in elasticsearch-model-7.0.0.pre vs spec/elasticsearch/model/indexing_spec.rb in elasticsearch-model-7.0.0

- old
+ new

@@ -416,11 +416,11 @@ before do expect(instance).to receive(:client).and_return(client) expect(instance).to receive(:as_indexed_json).and_return('JSON') expect(instance).to receive(:index_name).and_return('foo') - expect(instance).to receive(:document_type).and_return('bar') + expect(instance).to receive(:document_type).twice.and_return('bar') expect(instance).to receive(:id).and_return('1') end let(:client) do double('client') @@ -456,11 +456,11 @@ describe '#delete_document' do before do expect(instance).to receive(:client).and_return(client) expect(instance).to receive(:index_name).and_return('foo') - expect(instance).to receive(:document_type).and_return('bar') + expect(instance).to receive(:document_type).twice.and_return('bar') expect(instance).to receive(:id).and_return('1') end let(:client) do double('client') @@ -600,10 +600,10 @@ context 'when changes are present' do before do expect(instance).to receive(:client).and_return(client) expect(instance).to receive(:index_name).and_return('foo') - expect(instance).to receive(:document_type).and_return('bar') + expect(instance).to receive(:document_type).twice.and_return('bar') expect(instance).to receive(:id).and_return('1') instance.instance_variable_set(:@__changed_model_attributes, { author: 'john' }) end context 'when no options are specified' do