Commit 6f02da2c authored by Grzegorz Bizon's avatar Grzegorz Bizon

Simplify legacy CI config processor a little

parent 4491bf28
......@@ -26,7 +26,6 @@ module Ci
end
initial_parsing
validate!
rescue Gitlab::Ci::Config::Loader::FormatError => e
raise ValidationError, e.message
end
......@@ -71,6 +70,10 @@ module Ci
@ci_config.jobs.each do |name, param|
add_job(name, param)
end
@jobs.each do |name, job|
validate_job!(name, job)
end
end
def add_job(name, job)
......@@ -108,14 +111,6 @@ module Ci
}
end
def validate!
@jobs.each do |name, job|
validate_job!(name, job)
end
true
end
def validate_job!(name, job)
validate_job_name!(name)
validate_job_keys!(name, job)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment