Sha256: 67b4a0c6f395bbcbde1c4ed6c1b646e75762dea3aae0e4f9e2bb7c0a220bd020

Contents?: true

Size: 426 Bytes

Versions: 16

Compression:

Stored size: 426 Bytes

Contents

shared_examples_for 'a list-only command' do
  it 'raises an error for non-list values' do |example|
    key = 'mock-redis-test:list-only'

    method = method_from_description(example)
    args = args_for_method(method).unshift(key)

    @redises.set(key, 1)
    lambda do
      @redises.send(method, *args)
    end.should raise_error(RuntimeError)
  end

  it_should_behave_like 'does not remove empty strings on error'
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
mock_redis-0.32.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.31.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.30.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.29.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.28.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.27.3 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.27.2 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.27.1 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.27.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.26.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.25.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.24.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.23.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.22.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.21.0 spec/support/shared_examples/only_operates_on_lists.rb
mock_redis-0.20.0 spec/support/shared_examples/only_operates_on_lists.rb