summaryrefslogtreecommitdiff
path: root/spec/models/group_spec.rb
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-09-26 14:52:17 +0300
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-09-26 14:52:17 +0300
commit0a2a34a4d18d0489f7db6aad5b5518b503692b5b (patch)
treef169695667def43200565907636fae145469385d /spec/models/group_spec.rb
parent65b9768ccfbdc3de682d66430601cf3af1b2a2f8 (diff)
downloadgitlab-ce-0a2a34a4d18d0489f7db6aad5b5518b503692b5b.tar.gz
Ignore owner_id for Group in tests
Diffstat (limited to 'spec/models/group_spec.rb')
-rw-r--r--spec/models/group_spec.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/models/group_spec.rb b/spec/models/group_spec.rb
index 78c39548eb4..ce1aa05bcd7 100644
--- a/spec/models/group_spec.rb
+++ b/spec/models/group_spec.rb
@@ -26,10 +26,10 @@ describe Group do
it { should validate_uniqueness_of(:name) }
it { should validate_presence_of :path }
it { should validate_uniqueness_of(:path) }
- it { should validate_presence_of :owner }
+ it { should_not validate_presence_of :owner }
describe :users do
- it { group.users.should == [group.owner] }
+ it { group.users.should == group.owners }
end
describe :human_name do
@@ -38,7 +38,7 @@ describe Group do
describe :add_users do
let(:user) { create(:user) }
- before { group.add_users([user.id], UsersGroup::MASTER) }
+ before { group.add_user(user, UsersGroup::MASTER) }
it { group.users_groups.masters.map(&:user).should include(user) }
end