setting-for-account-deletable (#3852)
This commit is contained in:
parent
500e28442f
commit
ff142eb64d
5 changed files with 28 additions and 3 deletions
|
@ -68,5 +68,19 @@ describe Settings::DeletesController do
|
|||
expect(response).to redirect_to '/auth/sign_in'
|
||||
end
|
||||
end
|
||||
|
||||
context do
|
||||
around do |example|
|
||||
open_deletion = Setting.open_deletion
|
||||
example.run
|
||||
Setting.open_deletion = open_deletion
|
||||
end
|
||||
|
||||
it 'redirects' do
|
||||
Setting.open_deletion = false
|
||||
delete :destroy
|
||||
expect(response).to redirect_to root_path
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue