BigW Consortium Gitlab

06_teams.rb 435 Bytes
Newer Older
1
Gitlab::Seeder.quiet do
2 3
  Group.all.each do |group|
    User.all.sample(4).each do |user|
Dmitriy Zaporozhets committed
4
      if group.add_users([user.id], Gitlab::Access.values.sample)
5 6 7 8 9 10
        print '.'
      else
        print 'F'
      end
    end
  end
11

12 13
  Project.all.each do |project|
    User.all.sample(4).each do |user|
Dmitriy Zaporozhets committed
14
      if project.team << [user, Gitlab::Access.values.sample]
15 16 17 18
        print '.'
      else
        print 'F'
      end
19
    end
20 21
  end
end