spec/integration/riak/http_backends_spec.rb in riak-client-1.0.0.beta vs spec/integration/riak/http_backends_spec.rb in riak-client-1.0.0

- old
+ new

@@ -9,11 +9,11 @@ [:ExconBackend, :NetHTTPBackend].each do |klass| bklass = Riak::Client.const_get(klass) if bklass.configured? describe klass.to_s do before do - @backend = bklass.new(@client) + @backend = bklass.new(@client, @client.node) end it_should_behave_like "Unified backend API" end end @@ -32,10 +32,10 @@ class SizelessReader < Reader undef :size end describe 'NetHTTPBackend' do - subject { Riak::Client::NetHTTPBackend.new(@client) } + subject { Riak::Client::NetHTTPBackend.new(@client, @client.node) } let(:file) { File.open(__FILE__) } let(:sized) { Reader.new(["foo", "bar", "baz"]) } let(:sizeless) { SizelessReader.new(["foo", "bar", "baz"]) } it "should set the content-length or transfer-encoding properly on IO uploads" do lambda { subject.put(204, subject.object_path('nethttp', 'test-file'), file, {"Content-Type" => "text/plain"}) }.should_not raise_error