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
a89c366f
Commit
a89c366f
authored
Mar 01, 2019
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix bridge jobs than can be hidden keys too
parent
83e7e238
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
2 deletions
+10
-2
ee/lib/ee/gitlab/ci/config/entry/jobs.rb
ee/lib/ee/gitlab/ci/config/entry/jobs.rb
+4
-2
ee/spec/lib/gitlab/ci/config/entry/jobs_spec.rb
ee/spec/lib/gitlab/ci/config/entry/jobs_spec.rb
+6
-0
No files found.
ee/lib/ee/gitlab/ci/config/entry/jobs.rb
View file @
a89c366f
...
...
@@ -10,10 +10,12 @@ module EE
override
:node_type
def
node_type
(
name
)
if
bridge?
(
name
)
if
hidden?
(
name
)
::
Gitlab
::
Ci
::
Config
::
Entry
::
Hidden
elsif
bridge?
(
name
)
::
EE
::
Gitlab
::
Ci
::
Config
::
Entry
::
Bridge
else
super
::
Gitlab
::
Ci
::
Config
::
Entry
::
Job
end
end
...
...
ee/spec/lib/gitlab/ci/config/entry/jobs_spec.rb
View file @
a89c366f
...
...
@@ -5,6 +5,7 @@ describe Gitlab::Ci::Config::Entry::Jobs do
described_class
.
new
(
{
'.hidden_job'
.
to_sym
=>
{
script:
'something'
},
'.hidden_bridge'
.
to_sym
=>
{
trigger:
'my/project'
},
regular_job:
{
script:
'something'
},
my_trigger:
{
trigger:
'my/project'
}
}
...
...
@@ -24,6 +25,11 @@ describe Gitlab::Ci::Config::Entry::Jobs do
.
to
eq
::
Gitlab
::
Ci
::
Config
::
Entry
::
Hidden
end
it
'correctly identifies hidden bridge jobs'
do
expect
(
subject
.
node_type
(
:'.hidden_bridge'
))
.
to
eq
::
Gitlab
::
Ci
::
Config
::
Entry
::
Hidden
end
it
'correctly identifies regular jobs'
do
expect
(
subject
.
node_type
(
:regular_job
))
.
to
eq
::
Gitlab
::
Ci
::
Config
::
Entry
::
Job
...
...
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