mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 03:51:07 +08:00
DEV: Migrate sidebar site settings (#19336)
This new site setting replaces the `enable_experimental_sidebar_hamburger` and `enable_sidebar` site settings as the sidebar feature exits the experimental phase. Note that we're replacing this without depreciation since the previous site setting was considered experimental. Internal Ref: /t/86563
This commit is contained in:

committed by
GitHub

parent
f7f0ca801b
commit
fde9e6bc25
@ -833,24 +833,4 @@ RSpec.describe SiteSettingExtension do
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
describe 'sidebar category site settings' do
|
||||
describe '.all_settings' do
|
||||
before do
|
||||
settings.setting(:test_setting, 88, category: :sidebar)
|
||||
end
|
||||
|
||||
it 'does not include the sidebar category setting when enable_experimental_sidebar_hamburger site setting is disabled' do
|
||||
SiteSetting.enable_experimental_sidebar_hamburger = false
|
||||
|
||||
expect(settings.all_settings.detect { |s| s[:setting] == :test_setting }).to eq(nil)
|
||||
end
|
||||
|
||||
it 'includes the sidebar category setting when enable_experimental_sidebar_hamburger site setting is enabled' do
|
||||
SiteSetting.enable_experimental_sidebar_hamburger = true
|
||||
|
||||
expect(settings.all_settings.detect { |s| s[:setting] == :test_setting }[:setting]).to eq(:test_setting)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user