summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorAlexis Reigel <mail@koffeinfrei.org>2017-03-14 14:34:21 +0100
committerAlexis Reigel <mail@koffeinfrei.org>2017-04-06 10:01:14 +0200
commit1735ed613910b38c4c069da9c4637bbc4856db36 (patch)
tree7c7982af2bd8777bc919bef331edc9a0a1513eec /spec
parent20575859b1bf431421427d52c4ac5a33cf662df6 (diff)
downloadgitlab-ce-1735ed613910b38c4c069da9c4637bbc4856db36.tar.gz
rename cache db column with `_cached` suffix
Diffstat (limited to 'spec')
-rw-r--r--spec/controllers/application_controller_spec.rb4
-rw-r--r--spec/models/user_spec.rb8
2 files changed, 6 insertions, 6 deletions
diff --git a/spec/controllers/application_controller_spec.rb b/spec/controllers/application_controller_spec.rb
index 7427c93b593..760f33b09c1 100644
--- a/spec/controllers/application_controller_spec.rb
+++ b/spec/controllers/application_controller_spec.rb
@@ -183,7 +183,7 @@ describe ApplicationController do
end
it 'returns true if a 2FA requirement is set on the user' do
- user.require_two_factor_authentication = true
+ user.require_two_factor_authentication_from_group = true
allow(controller).to receive(:current_user).and_return(user)
expect(subject).to be_truthy
@@ -201,7 +201,7 @@ describe ApplicationController do
end
context 'with a 2FA requirement set on the user' do
- let(:user) { create :user, require_two_factor_authentication: true, two_factor_grace_period: 23 }
+ let(:user) { create :user, require_two_factor_authentication_from_group: true, two_factor_grace_period: 23 }
it 'returns the user grace period if lower than the application grace period' do
stub_application_setting two_factor_grace_period: 24
diff --git a/spec/models/user_spec.rb b/spec/models/user_spec.rb
index ddd438bfc25..3977af55176 100644
--- a/spec/models/user_spec.rb
+++ b/spec/models/user_spec.rb
@@ -1548,7 +1548,7 @@ describe User, models: true do
end
it 'requires 2FA' do
- expect(user.require_two_factor_authentication).to be true
+ expect(user.require_two_factor_authentication_from_group).to be true
end
it 'uses the shortest grace period' do
@@ -1567,7 +1567,7 @@ describe User, models: true do
end
it 'requires 2FA' do
- expect(user.require_two_factor_authentication).to be true
+ expect(user.require_two_factor_authentication_from_group).to be true
end
end
@@ -1582,7 +1582,7 @@ describe User, models: true do
end
it 'requires 2FA' do
- expect(user.require_two_factor_authentication).to be true
+ expect(user.require_two_factor_authentication_from_group).to be true
end
end
@@ -1596,7 +1596,7 @@ describe User, models: true do
end
it 'does not require 2FA' do
- expect(user.require_two_factor_authentication).to be false
+ expect(user.require_two_factor_authentication_from_group).to be false
end
it 'falls back to the default grace period' do