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
0
Merge Requests
0
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
Léo-Paul Géneau
gitlab-ce
Commits
6bec8cbd
Commit
6bec8cbd
authored
May 20, 2019
by
Vladimir Shushlin
Committed by
Nick Thomas
May 20, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove remove_disabled_domains feature flag
parent
5666c8eb
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
17 deletions
+0
-17
app/workers/pages_domain_removal_cron_worker.rb
app/workers/pages_domain_removal_cron_worker.rb
+0
-2
spec/workers/pages_domain_removal_cron_worker_spec.rb
spec/workers/pages_domain_removal_cron_worker_spec.rb
+0
-15
No files found.
app/workers/pages_domain_removal_cron_worker.rb
View file @
6bec8cbd
...
...
@@ -5,8 +5,6 @@ class PagesDomainRemovalCronWorker
include
CronjobQueue
def
perform
return
unless
Feature
.
enabled?
(
:remove_disabled_domains
)
PagesDomain
.
for_removal
.
find_each
do
|
domain
|
domain
.
destroy!
rescue
=>
e
...
...
spec/workers/pages_domain_removal_cron_worker_spec.rb
View file @
6bec8cbd
...
...
@@ -9,25 +9,10 @@ describe PagesDomainRemovalCronWorker do
context
'when there is domain which should be removed'
do
let!
(
:domain_for_removal
)
{
create
(
:pages_domain
,
:should_be_removed
)
}
before
do
stub_feature_flags
(
remove_disabled_domains:
true
)
end
it
'removes domain'
do
expect
{
worker
.
perform
}.
to
change
{
PagesDomain
.
count
}.
by
(
-
1
)
expect
(
PagesDomain
.
exists?
).
to
eq
(
false
)
end
context
'when domain removal is disabled'
do
before
do
stub_feature_flags
(
remove_disabled_domains:
false
)
end
it
'does not remove pages domain'
do
expect
{
worker
.
perform
}.
not_to
change
{
PagesDomain
.
count
}
expect
(
PagesDomain
.
find_by
(
domain:
domain_for_removal
.
domain
)).
to
be_present
end
end
end
context
'where there is a domain which scheduled for removal in the future'
do
...
...
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