summaryrefslogtreecommitdiff
path: root/db/fixtures
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-11-20 12:06:01 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2019-11-20 12:06:01 +0000
commita68e9d3318c6847436f81f83eb347b29f52d1bff (patch)
tree511a790297f7e771f8d73025b9a1f9b4a0586d71 /db/fixtures
parent7bc0aff0b4e15fce828621d7e0919d84368f3d2b (diff)
downloadgitlab-ce-a68e9d3318c6847436f81f83eb347b29f52d1bff.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'db/fixtures')
-rw-r--r--db/fixtures/development/02_users.rb3
-rw-r--r--db/fixtures/development/03_project.rb3
2 files changed, 2 insertions, 4 deletions
diff --git a/db/fixtures/development/02_users.rb b/db/fixtures/development/02_users.rb
index 6e0b37d7258..909d10cbb40 100644
--- a/db/fixtures/development/02_users.rb
+++ b/db/fixtures/development/02_users.rb
@@ -5,7 +5,6 @@ class Gitlab::Seeder::Users
RANDOM_USERS_COUNT = 20
MASS_USERS_COUNT = ENV['CI'] ? 10 : 1_000_000
- MASS_INSERT_USERNAME_START = 'mass_insert_user_'
attr_reader :opts
@@ -29,7 +28,7 @@ class Gitlab::Seeder::Users
ActiveRecord::Base.connection.execute <<~SQL
INSERT INTO users (username, name, email, confirmed_at, projects_limit, encrypted_password)
SELECT
- '#{MASS_INSERT_USERNAME_START}' || seq,
+ '#{Gitlab::Seeder::MASS_INSERT_USER_START}' || seq,
'Seed user ' || seq,
'seed_user' || seq || '@example.com',
to_timestamp(seq),
diff --git a/db/fixtures/development/03_project.rb b/db/fixtures/development/03_project.rb
index 87ef65276eb..19800a65cab 100644
--- a/db/fixtures/development/03_project.rb
+++ b/db/fixtures/development/03_project.rb
@@ -52,7 +52,6 @@ class Gitlab::Seeder::Projects
internal: 1, # 1m projects +
public: 1 # 1m projects = 5m total
}
- MASS_INSERT_NAME_START = 'mass_insert_project_'
def seed!
Sidekiq::Testing.inline! do
@@ -167,7 +166,7 @@ class Gitlab::Seeder::Projects
INSERT INTO projects (name, path, creator_id, namespace_id, visibility_level, created_at, updated_at)
SELECT
'Seed project ' || seq || ' ' || ('{#{visibility_per_user}}'::text[])[seq] AS project_name,
- 'mass_insert_project_' || ('{#{visibility_per_user}}'::text[])[seq] || '_' || seq AS project_path,
+ '#{Gitlab::Seeder::MASS_INSERT_PROJECT_START}' || ('{#{visibility_per_user}}'::text[])[seq] || '_' || seq AS project_path,
u.id AS user_id,
n.id AS namespace_id,
('{#{visibility_level_per_user}}'::int[])[seq] AS visibility_level,