blob: fa16b2a1d934343ab541d14e66b53b8000d1a908 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
require './spec/support/sidekiq'
Sidekiq::Testing.inline! do
Gitlab::Seeder.quiet do
User.not_mass_generated.sample(10).each do |user|
source_project = Project.not_mass_generated.public_only.sample
##
# 03_project.rb might not have created a public project because
# we use randomized approach (e.g. `Array#sample`).
return unless source_project
fork_project = Projects::ForkService.new(
source_project,
user,
namespace: user.namespace,
skip_disk_validation: true
).execute
if fork_project.valid?
print '.'
else
print 'F'
end
end
end
end
|