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

Remove CI job script validation from legacy config

parent 500b61e1
...@@ -110,7 +110,6 @@ module Ci ...@@ -110,7 +110,6 @@ module Ci
validate_job_name!(name) validate_job_name!(name)
validate_job_keys!(name, job) validate_job_keys!(name, job)
validate_job_types!(name, job) validate_job_types!(name, job)
validate_job_script!(name, job)
validate_job_variables!(name, job) if job[:variables] validate_job_variables!(name, job) if job[:variables]
validate_job_cache!(name, job) if job[:cache] validate_job_cache!(name, job) if job[:cache]
...@@ -166,20 +165,6 @@ module Ci ...@@ -166,20 +165,6 @@ module Ci
end end
end end
def validate_job_script!(name, job)
if !validate_string(job[:script]) && !validate_array_of_strings(job[:script])
raise ValidationError, "#{name} job: script should be a string or an array of a strings"
end
if job[:before_script] && !validate_array_of_strings(job[:before_script])
raise ValidationError, "#{name} job: before_script should be an array of strings"
end
if job[:after_script] && !validate_array_of_strings(job[:after_script])
raise ValidationError, "#{name} job: after_script should be an array of strings"
end
end
def validate_job_variables!(name, job) def validate_job_variables!(name, job)
unless validate_variables(job[:variables]) unless validate_variables(job[:variables])
raise ValidationError, raise ValidationError,
......
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