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
49cbe576
Commit
49cbe576
authored
May 03, 2018
by
Dylan Griffith
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove Runner#belonging_to_any_project since this is no longer needed
parent
d39b3d4b
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
18 deletions
+0
-18
app/controllers/projects/settings/ci_cd_controller.rb
app/controllers/projects/settings/ci_cd_controller.rb
+0
-1
app/models/ci/runner.rb
app/models/ci/runner.rb
+0
-2
spec/models/ci/runner_spec.rb
spec/models/ci/runner_spec.rb
+0
-15
No files found.
app/controllers/projects/settings/ci_cd_controller.rb
View file @
49cbe576
...
...
@@ -72,7 +72,6 @@ module Projects
.
ci_authorized_runners
.
assignable_for
(
project
)
.
ordered
.
belonging_to_any_project
.
page
(
params
[
:page
]).
per
(
20
)
@shared_runners
=
::
Ci
::
Runner
.
shared
.
active
...
...
app/models/ci/runner.rb
View file @
49cbe576
...
...
@@ -32,8 +32,6 @@ module Ci
joins
(
:runner_projects
).
where
(
ci_runner_projects:
{
project_id:
project_id
})
}
scope
:belonging_to_any_project
,
->
{
joins
(
:runner_projects
)
}
scope
:belonging_to_parent_group_of_project
,
->
(
project_id
)
{
project_groups
=
::
Group
.
joins
(
:projects
).
where
(
projects:
{
id:
project_id
})
hierarchy_groups
=
Gitlab
::
GroupHierarchy
.
new
(
project_groups
).
base_and_ancestors
...
...
spec/models/ci/runner_spec.rb
View file @
49cbe576
...
...
@@ -137,21 +137,6 @@ describe Ci::Runner do
end
end
describe
'.belonging_to_any_project'
do
it
'returns the specific project runner'
do
# project
project_project
=
create
(
:project
)
project_runner
=
create
(
:ci_runner
,
:specific
,
projects:
[
project_project
])
# group
group
=
create
(
:group
)
create
(
:project
,
group:
group
)
create
(
:ci_runner
,
:specific
,
groups:
[
group
])
expect
(
described_class
.
belonging_to_any_project
).
to
eq
[
project_runner
]
end
end
describe
'.belonging_to_parent_group_of_project'
do
let
(
:project
)
{
create
(
:project
,
group:
group
)
}
let
(
:group
)
{
create
(
:group
)
}
...
...
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