0
0
Fork 0

Autofix Rubocop RSpec/BeEq (#23740)

This commit is contained in:
Nick Schonning 2023-02-20 00:14:50 -05:00 committed by GitHub
parent bf785df9fe
commit 5116347eb7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
39 changed files with 139 additions and 182 deletions

View file

@ -57,19 +57,19 @@ describe ApplicationController, type: :controller do
describe 'helper_method :single_user_mode?' do
it 'returns false if it is in single_user_mode but there is no account' do
allow(Rails.configuration.x).to receive(:single_user_mode).and_return(true)
expect(controller.view_context.single_user_mode?).to eq false
expect(controller.view_context.single_user_mode?).to be false
end
it 'returns false if there is an account but it is not in single_user_mode' do
allow(Rails.configuration.x).to receive(:single_user_mode).and_return(false)
Fabricate(:account)
expect(controller.view_context.single_user_mode?).to eq false
expect(controller.view_context.single_user_mode?).to be false
end
it 'returns true if it is in single_user_mode and there is an account' do
allow(Rails.configuration.x).to receive(:single_user_mode).and_return(true)
Fabricate(:account)
expect(controller.view_context.single_user_mode?).to eq true
expect(controller.view_context.single_user_mode?).to be true
end
end