Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
0a97ae31
Commit
0a97ae31
authored
Sep 13, 2019
by
rpereira2
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove self monitoring project migration
parent
f0636248
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
57 deletions
+0
-57
db/post_migrate/20190801072937_add_gitlab_instance_administration_project.rb
...90801072937_add_gitlab_instance_administration_project.rb
+0
-18
spec/migrations/add_gitlab_instance_administration_project_spec.rb
...ations/add_gitlab_instance_administration_project_spec.rb
+0
-39
No files found.
db/post_migrate/20190801072937_add_gitlab_instance_administration_project.rb
deleted
100644 → 0
View file @
f0636248
# frozen_string_literal: true
class
AddGitlabInstanceAdministrationProject
<
ActiveRecord
::
Migration
[
5.2
]
DOWNTIME
=
false
disable_ddl_transaction!
def
up
BackgroundMigrationWorker
.
perform_async
(
'AddGitlabInstanceAdministrationProject'
,
[])
end
def
down
ApplicationSetting
.
current_without_cache
&
.
instance_administration_project
&
.
owner
&
.
destroy!
end
end
spec/migrations/add_gitlab_instance_administration_project_spec.rb
deleted
100644 → 0
View file @
f0636248
# frozen_string_literal: true
require
'spec_helper'
require
Rails
.
root
.
join
(
'db'
,
'post_migrate'
,
'20190801072937_add_gitlab_instance_administration_project.rb'
)
describe
AddGitlabInstanceAdministrationProject
,
:migration
do
let
(
:application_settings
)
{
table
(
:application_settings
)
}
let
(
:users
)
{
table
(
:users
)
}
let
(
:prometheus_settings
)
do
{
enable:
true
,
listen_address:
'localhost:9090'
}
end
before
do
stub_env
(
'IN_MEMORY_APPLICATION_SETTINGS'
,
'false'
)
stub_config
(
prometheus:
prometheus_settings
)
end
describe
'down'
do
let!
(
:application_setting
)
{
application_settings
.
create!
}
let!
(
:user
)
{
users
.
create!
(
admin:
true
,
email:
'admin1@example.com'
,
projects_limit:
10
,
state: :active
)
}
it
'deletes group and project'
do
migrate!
expect
(
Project
.
count
).
to
eq
(
1
)
expect
(
Group
.
count
).
to
eq
(
1
)
schema_migrate_down!
expect
(
Project
.
count
).
to
eq
(
0
)
expect
(
Group
.
count
).
to
eq
(
0
)
end
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment