2021-07-07 18:57:42 +02:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2022-07-28 05:27:38 +03:00
|
|
|
RSpec.describe SiteSettingExtension, type: :multisite do
|
2023-01-09 11:18:21 +00:00
|
|
|
before { MessageBus.off }
|
2021-07-07 18:57:42 +02:00
|
|
|
|
2023-01-09 11:18:21 +00:00
|
|
|
after { MessageBus.on }
|
2021-07-07 18:57:42 +02:00
|
|
|
|
2023-01-09 11:18:21 +00:00
|
|
|
let(:provider_local) { SiteSettings::LocalProcessProvider.new }
|
2021-07-07 18:57:42 +02:00
|
|
|
|
2023-01-09 11:18:21 +00:00
|
|
|
let(:settings) { new_settings(provider_local) }
|
2021-07-07 18:57:42 +02:00
|
|
|
|
|
|
|
it "has no db cross talk" do
|
|
|
|
settings.setting(:hello, 1)
|
|
|
|
settings.hello = 100
|
|
|
|
|
2023-01-09 11:18:21 +00:00
|
|
|
test_multisite_connection("second") { expect(settings.hello).to eq(1) }
|
2021-07-07 18:57:42 +02:00
|
|
|
end
|
|
|
|
end
|