spec/lib/backends/sqlite/directly_manipulable_spec.rb in picky-4.19.4 vs spec/lib/backends/sqlite/directly_manipulable_spec.rb in picky-4.19.5

- old
+ new

@@ -1,20 +1,20 @@ require 'spec_helper' describe Picky::Backends::SQLite::DirectlyManipulable do - let(:client) { stub :client } - let(:backend) { stub :backend, client: client, namespace: 'some:namespace' } + let(:client) { double :client } + let(:backend) { double :backend, client: client, namespace: 'some:namespace' } let(:array) do array = [1,2] described_class.make backend, array, 'some:key' array end context 'stubbed backend' do before(:each) do - backend.stub! :[] + backend.stub :[] end it 'calls the right client method' do backend.should_receive(:[]=).once.with 'some:key', [1,2,3] array << 3 @@ -36,10 +36,10 @@ end end context 'stubbed client/backend' do before(:each) do - backend.stub! :[]= + backend.stub :[]= end it 'behaves like an ordinary Array' do array << 3 array.should == [1,2,3] \ No newline at end of file