diff options
Diffstat (limited to 'spec/lib/gitlab/workhorse_spec.rb')
-rw-r--r-- | spec/lib/gitlab/workhorse_spec.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/spec/lib/gitlab/workhorse_spec.rb b/spec/lib/gitlab/workhorse_spec.rb index 703a4b5399e..7209263445c 100644 --- a/spec/lib/gitlab/workhorse_spec.rb +++ b/spec/lib/gitlab/workhorse_spec.rb @@ -366,9 +366,25 @@ RSpec.describe Gitlab::Workhorse do expect(Gitlab::Redis::SharedState).to receive(:with).and_call_original expect_any_instance_of(::Redis).to receive(:publish) .with(described_class::NOTIFICATION_CHANNEL, "test-key=test-value") + expect_any_instance_of(::Redis).to receive(:publish) + .with(described_class::NOTIFICATION_CHANNEL + ':test-key', "test-value") subject end + + context 'when workhorse_long_polling_publish_many is disabled' do + before do + stub_feature_flags(workhorse_long_polling_publish_many: false) + end + + it 'set and notify' do + expect(Gitlab::Redis::SharedState).to receive(:with).and_call_original + expect_any_instance_of(::Redis).to receive(:publish) + .with(described_class::NOTIFICATION_CHANNEL, "test-key=test-value") + + subject + end + end end context 'when we set a new key' do |