Sha256: 304cfa7eda29809b412112778207a3e42b817cc4085723f7af7282c906e16ec4
Contents?: true
Size: 618 Bytes
Versions: 39
Compression:
Stored size: 618 Bytes
Contents
require 'spec_helper' describe '#append(key, value)' do before { @key = 'mock-redis-test:append' } it "returns the new length of the string" do @redises.set(@key, 'porkchop') @redises.append(@key, 'sandwiches').should == 18 end it "appends value to the previously-stored value" do @redises.set(@key, 'porkchop') @redises.append(@key, 'sandwiches') @redises.get(@key).should == 'porkchopsandwiches' end it "treats a missing key as an empty string" do @redises.append(@key, 'foo') @redises.get(@key).should == 'foo' end it_should_behave_like "a string-only command" end
Version data entries
39 entries across 39 versions & 2 rubygems