Sha256: 9d8573b7f78f879723715998e012f5e5435b652581afae2368df9834beb0250c

Contents?: true

Size: 663 Bytes

Versions: 1

Compression:

Stored size: 663 Bytes

Contents

require 'helper'
require 'flipper/adapters/memory'
require 'flipper/adapters/dalli'
require 'flipper/spec/shared_adapter_specs'

RSpec.describe Flipper::Adapters::Dalli do
  let(:memory_adapter) { Flipper::Adapters::Memory.new }
  let(:cache)   { Dalli::Client.new(ENV["BOXEN_MEMCACHED_URL"] || '127.0.0.1:11211') }
  let(:adapter) { Flipper::Adapters::Dalli.new(memory_adapter, cache) }
  let(:flipper) { Flipper.new(adapter) }

  subject { described_class.new(adapter, cache) }

  before do
    cache.flush
  end

  it_should_behave_like 'a flipper adapter'

  describe "#name" do
    it "is dalli" do
      expect(subject.name).to be(:dalli)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
flipper-dalli-0.10.1 spec/flipper/adapters/dalli_spec.rb