diff options
Diffstat (limited to 'spec/tasks/gitlab/cleanup_rake_spec.rb')
-rw-r--r-- | spec/tasks/gitlab/cleanup_rake_spec.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/tasks/gitlab/cleanup_rake_spec.rb b/spec/tasks/gitlab/cleanup_rake_spec.rb index 16c907ca87c..0291f14fe4e 100644 --- a/spec/tasks/gitlab/cleanup_rake_spec.rb +++ b/spec/tasks/gitlab/cleanup_rake_spec.rb @@ -166,14 +166,14 @@ RSpec.describe 'gitlab:cleanup rake tasks', :silence_stdout do end context 'sessions' do - describe 'gitlab:cleanup:sessions:active_sessions_lookup_keys', :clean_gitlab_redis_shared_state do + describe 'gitlab:cleanup:sessions:active_sessions_lookup_keys', :clean_gitlab_redis_sessions do subject(:rake_task) { run_rake_task('gitlab:cleanup:sessions:active_sessions_lookup_keys') } let!(:user) { create(:user) } let(:existing_session_id) { '5' } before do - Gitlab::Redis::SharedState.with do |redis| + Gitlab::Redis::Sessions.with do |redis| redis.set("session:user:gitlab:#{user.id}:#{existing_session_id}", Marshal.dump(true)) redis.sadd("session:lookup:user:gitlab:#{user.id}", (1..10).to_a) @@ -185,7 +185,7 @@ RSpec.describe 'gitlab:cleanup rake tasks', :silence_stdout do end it 'removes expired active session lookup keys' do - Gitlab::Redis::SharedState.with do |redis| + Gitlab::Redis::Sessions.with do |redis| lookup_key = "session:lookup:user:gitlab:#{user.id}" expect { subject }.to change { redis.scard(lookup_key) }.from(10).to(1) expect(redis.smembers("session:lookup:user:gitlab:#{user.id}")).to( |