diff --git a/spec/features/event_register_managed_spec.rb b/spec/features/event_register_managed_spec.rb index f056ecd..613dc33 100644 --- a/spec/features/event_register_managed_spec.rb +++ b/spec/features/event_register_managed_spec.rb @@ -32,6 +32,7 @@ context 'with feature toggle disabled' do before do + allow(FeatureGate).to receive(:enabled?).with(:self_registration_reason).and_return(false) allow(FeatureGate).to receive(:enabled?).with('people.people_managers').and_return(false) end @@ -46,6 +47,7 @@ context 'with feature toggle enabled' do before do + allow(FeatureGate).to receive(:enabled?).with(:self_registration_reason).and_return(false) allow(FeatureGate).to receive(:enabled?).with('people.people_managers').and_return(true) end @@ -103,6 +105,7 @@ context 'with feature toggle disabled' do before do + allow(FeatureGate).to receive(:enabled?).with(:self_registration_reason).and_return(false) allow(FeatureGate).to receive(:enabled?).with('people.people_managers').and_return(false) end @@ -115,6 +118,7 @@ context 'with feature toggle enabled' do before do + allow(FeatureGate).to receive(:enabled?).with(:self_registration_reason).and_return(false) allow(FeatureGate).to receive(:enabled?).with('people.people_managers').and_return(true) end @@ -153,6 +157,7 @@ describe 'registering new managed' do context 'with feature toggle disabled' do before do + allow(FeatureGate).to receive(:enabled?).with(:self_registration_reason).and_return(false) allow(FeatureGate).to receive(:enabled?).with('people.people_managers').and_return(false) end @@ -167,6 +172,7 @@ context 'with feature toggle enabled' do before do + allow(FeatureGate).to receive(:enabled?).with(:self_registration_reason).and_return(false) allow(FeatureGate).to receive(:enabled?).with('people.people_managers').and_return(true) end diff --git a/spec/features/external_event_register_manager_spec.rb b/spec/features/external_event_register_manager_spec.rb index 9fa6a3e..747fbae 100644 --- a/spec/features/external_event_register_manager_spec.rb +++ b/spec/features/external_event_register_manager_spec.rb @@ -30,6 +30,7 @@ context 'with feature toggle enabled' do before do + allow(FeatureGate).to receive(:enabled?).with(:self_registration_reason).and_return(false) allow(FeatureGate).to receive(:enabled?).with('groups.self_registration').and_return(false) allow(FeatureGate).to receive(:enabled?).with('people.people_managers').and_return(true) allow_any_instance_of(FeatureGate).to receive(:enabled?).and_return(true)