spec/commands/brpoplpush_spec.rb in mock_redis-0.4.1 vs spec/commands/brpoplpush_spec.rb in mock_redis-0.5.0
- old
+ new
@@ -22,19 +22,19 @@
it "returns the moved element" do
@redises.brpoplpush(@list1, @list2, 0).should == "B"
end
- it "raises an error on non-integer timeout" do
+ it "allows subsecond timeout" do
lambda do
@redises.brpoplpush(@list1, @list2, 0.5)
- end.should raise_error(RuntimeError)
+ end.should_not raise_error(Redis::CommandError)
end
it "raises an error on negative timeout" do
lambda do
@redises.brpoplpush(@list1, @list2, -1)
- end.should raise_error(RuntimeError)
+ end.should raise_error(Redis::CommandError)
end
it_should_behave_like "a list-only command"
context "[mock only]" do