Commit fccf699e authored by sfang97's avatar sfang97

Add changelog entry

Remove uneeded test
Remove feature enabled from spec name
Fix changelog typo
parent 24a6292e
---
title: Remove admin_approval_for_new_user_signups feature flag
merge_request: 46051
author:
type: changed
...@@ -107,7 +107,6 @@ RSpec.describe Admin::UsersController do ...@@ -107,7 +107,6 @@ RSpec.describe Admin::UsersController do
subject { put :approve, params: { id: user.username } } subject { put :approve, params: { id: user.username } }
context 'when feature is enabled' do
context 'when successful' do context 'when successful' do
it 'activates the user' do it 'activates the user' do
subject subject
...@@ -136,7 +135,6 @@ RSpec.describe Admin::UsersController do ...@@ -136,7 +135,6 @@ RSpec.describe Admin::UsersController do
end end
end end
end end
end
describe 'PUT #activate' do describe 'PUT #activate' do
shared_examples 'a request that activates the user' do shared_examples 'a request that activates the user' do
......
...@@ -46,7 +46,6 @@ RSpec.describe RegistrationsController do ...@@ -46,7 +46,6 @@ RSpec.describe RegistrationsController do
subject { post(:create, params: user_params) } subject { post(:create, params: user_params) }
context '`blocked_pending_approval` state' do context '`blocked_pending_approval` state' do
context 'when the feature is enabled' do
context 'when the `require_admin_approval_after_user_signup` setting is turned on' do context 'when the `require_admin_approval_after_user_signup` setting is turned on' do
before do before do
stub_application_setting(require_admin_approval_after_user_signup: true) stub_application_setting(require_admin_approval_after_user_signup: true)
...@@ -122,23 +121,6 @@ RSpec.describe RegistrationsController do ...@@ -122,23 +121,6 @@ RSpec.describe RegistrationsController do
end end
end end
context 'when the feature is disabled' do
context 'when the `require_admin_approval_after_user_signup` setting is turned on' do
before do
stub_application_setting(require_admin_approval_after_user_signup: true)
end
it 'signs up the user in `active` state' do
subject
created_user = User.find_by(email: 'new@user.com')
expect(created_user).to be_present
expect(created_user.active?).to eq(true)
end
end
end
end
context 'email confirmation' do context 'email confirmation' do
context 'when send_user_confirmation_email is false' do context 'when send_user_confirmation_email is false' do
it 'signs the user in' do it 'signs the user in' do
......
...@@ -132,7 +132,6 @@ RSpec.describe 'Admin updates settings', :clean_gitlab_redis_shared_state, :do_n ...@@ -132,7 +132,6 @@ RSpec.describe 'Admin updates settings', :clean_gitlab_redis_shared_state, :do_n
context 'Change Sign-up restrictions' do context 'Change Sign-up restrictions' do
context 'Require Admin approval for new signup setting' do context 'Require Admin approval for new signup setting' do
context 'when feature is enabled' do
it 'changes the setting' do it 'changes the setting' do
page.within('.as-signup') do page.within('.as-signup') do
check 'Require admin approval for new sign-ups' check 'Require admin approval for new sign-ups'
...@@ -144,7 +143,6 @@ RSpec.describe 'Admin updates settings', :clean_gitlab_redis_shared_state, :do_n ...@@ -144,7 +143,6 @@ RSpec.describe 'Admin updates settings', :clean_gitlab_redis_shared_state, :do_n
end end
end end
end end
end
it 'Change Sign-in restrictions' do it 'Change Sign-in restrictions' do
page.within('.as-signin') do page.within('.as-signin') do
......
...@@ -75,7 +75,6 @@ RSpec.describe "Admin::Users" do ...@@ -75,7 +75,6 @@ RSpec.describe "Admin::Users" do
end end
context '`Pending approval` tab' do context '`Pending approval` tab' do
context 'feature is enabled' do
before do before do
visit admin_users_path visit admin_users_path
end end
...@@ -85,7 +84,6 @@ RSpec.describe "Admin::Users" do ...@@ -85,7 +84,6 @@ RSpec.describe "Admin::Users" do
end end
end end
end end
end
describe 'search and sort' do describe 'search and sort' do
before do before do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment