diff options
Diffstat (limited to 'spec/config/settings_spec.rb')
-rw-r--r-- | spec/config/settings_spec.rb | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/spec/config/settings_spec.rb b/spec/config/settings_spec.rb index 0928f2b72ff..b464a4eee8b 100644 --- a/spec/config/settings_spec.rb +++ b/spec/config/settings_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe Settings, feature_category: :authentication_and_authorization do +RSpec.describe Settings, feature_category: :system_access do using RSpec::Parameterized::TableSyntax describe 'omniauth' do @@ -198,4 +198,18 @@ RSpec.describe Settings, feature_category: :authentication_and_authorization do end end end + + describe '.build_sidekiq_routing_rules' do + using RSpec::Parameterized::TableSyntax + + where(:input_rules, :result) do + nil | [['*', nil]] + [] | [['*', nil]] + [['name=foobar', 'foobar']] | [['name=foobar', 'foobar']] + end + + with_them do + it { expect(described_class.send(:build_sidekiq_routing_rules, input_rules)).to eq(result) } + end + end end |