diff options
author | Douwe Maan <douwe@gitlab.com> | 2015-03-13 16:40:15 +0100 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2015-03-13 22:34:11 +0100 |
commit | 8fed435208fed3115c740eb630c263a97b5a631d (patch) | |
tree | b19988b7d9590761f8398c6c1b027b69395bb3fb /spec | |
parent | 606d24ff2df157ec70003132d1ead7a47dc32883 (diff) | |
download | gitlab-ce-8fed435208fed3115c740eb630c263a97b5a631d.tar.gz |
Unblock user if they were unblocked in AD.
Diffstat (limited to 'spec')
-rw-r--r-- | spec/lib/gitlab/ldap/access_spec.rb | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/spec/lib/gitlab/ldap/access_spec.rb b/spec/lib/gitlab/ldap/access_spec.rb index 39d46efcbc3..707a0521ab3 100644 --- a/spec/lib/gitlab/ldap/access_spec.rb +++ b/spec/lib/gitlab/ldap/access_spec.rb @@ -28,9 +28,18 @@ describe Gitlab::LDAP::Access do end context 'and has no disabled flag in active diretory' do - before { Gitlab::LDAP::Person.stub(disabled_via_active_directory?: false) } + before do + user.block + + Gitlab::LDAP::Person.stub(disabled_via_active_directory?: false) + end it { is_expected.to be_truthy } + + it "should unblock user in GitLab" do + access.allowed? + user.should_not be_blocked + end end context 'without ActiveDirectory enabled' do |