From 0f32f0dfd284cd389631853c85369b813eef59f2 Mon Sep 17 00:00:00 2001 From: Didier Lafforgue Date: Fri, 28 Feb 2020 12:20:39 +0100 Subject: [PATCH] fix specs --- spec/unit/middlewares/cache_spec.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/spec/unit/middlewares/cache_spec.rb b/spec/unit/middlewares/cache_spec.rb index 21c5b3b6..5b24322b 100644 --- a/spec/unit/middlewares/cache_spec.rb +++ b/spec/unit/middlewares/cache_spec.rb @@ -55,11 +55,11 @@ let(:response) { nil } - before { expect(cache).to receive(:read).with('2fae60bf8d7d9c0dce6cabcac8288267').and_return(response) } + before { expect(cache).to receive(:read).with('d067eb71e255c31cd3cff107c3a0c9e9').and_return(response) } context 'the cache is empty' do - before { expect(cache).to receive(:write).with('2fae60bf8d7d9c0dce6cabcac8288267', Marshal.dump([200, {}, ["Hello world!"]])) } + before { expect(cache).to receive(:write).with('d067eb71e255c31cd3cff107c3a0c9e9', Marshal.dump([200, {}, ["Hello world!"]])) } it 'tells the CDN to cache the page and also cache it internally' do is_expected.to eq ['max-age=0, s-maxage=3600, public, must-revalidate', 'Accept-Language'] @@ -69,7 +69,7 @@ subject { send_request[:env]['steam.cache_etag'] } - it { is_expected.to eq '2fae60bf8d7d9c0dce6cabcac8288267' } + it { is_expected.to eq 'd067eb71e255c31cd3cff107c3a0c9e9' } end @@ -104,7 +104,7 @@ context 'based on the ETag' do - let(:etag) { '2fae60bf8d7d9c0dce6cabcac8288267' } + let(:etag) { 'd067eb71e255c31cd3cff107c3a0c9e9' } it 'returns a 304 (Not modified) without no cache headers' do expect(subject.first).to eq 304