diff options
author | Timothy Andrew <mail@timothyandrew.net> | 2017-02-21 12:50:05 +0530 |
---|---|---|
committer | Timothy Andrew <mail@timothyandrew.net> | 2017-02-24 16:50:21 +0530 |
commit | 53aa043724a0395a2f95f41b8f3fb4c308691874 (patch) | |
tree | 9a495acefdab3f45f3422d09177a0168c0906cc7 /spec/models/user_spec.rb | |
parent | 6fdb17cbbe5dc70d18f50e9d131ab70407976a71 (diff) | |
download | gitlab-ce-53aa043724a0395a2f95f41b8f3fb4c308691874.tar.gz |
Fix specs for the ghost user feature.12726-preserve-issues-after-deleting-users
Diffstat (limited to 'spec/models/user_spec.rb')
-rw-r--r-- | spec/models/user_spec.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/spec/models/user_spec.rb b/spec/models/user_spec.rb index 9e2b1c9290f..6356f8b6c92 100644 --- a/spec/models/user_spec.rb +++ b/spec/models/user_spec.rb @@ -211,13 +211,15 @@ describe User, models: true do describe 'ghost users' do it 'does not allow a non-blocked ghost user' do - user = build(:user, :ghost, state: :active) + user = build(:user, :ghost) + user.state = 'active' expect(user).to be_invalid end it 'allows a blocked ghost user' do - user = build(:user, :ghost, state: :blocked) + user = build(:user, :ghost) + user.state = 'blocked' expect(user).to be_valid end |