Sha256: 5f6b00323432650165173b36a8086b28b5948d397dfc98fb94892432534d4725
Contents?: true
Size: 684 Bytes
Versions: 1
Compression:
Stored size: 684 Bytes
Contents
require 'spec_helper' class FakeKeyValueStore end describe Roulette::EachStore do before do @key = "key" @args = [@key, "value"] @stores = [FakeKeyValueStore.new, FakeKeyValueStore.new] end describe '#new' do it "keeps stores" do each_store = Roulette::EachStore.new(@stores) each_store.stores.should eq(@stores) end end describe "#method_missing" do it "sends any method to all stores" do fired_method = :sadd @stores.each do |store| store.should_receive(fired_method).with(@args) end Roulette::EachStore.new(@stores).send fired_method, *@args end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
roulette-0.0.5 | spec/roulette/each_store_spec.rb |