trabajo-afectivo/spec/lib/cache_spec.rb

14 lines
275 B
Ruby
Raw Normal View History

require 'rails_helper'
RSpec.describe Cache do
describe '.get' do
before { allow(Rails.cache).to receive(:read) }
it 'alias of Rails.cache.read' do
described_class.read('foo')
expect(Rails.cache).to have_received(:read).with('foo')
end
end
end