diff options
author | Kamil Trzcinski <ayufan@ayufan.eu> | 2015-07-08 12:38:08 +0200 |
---|---|---|
committer | Kamil Trzcinski <ayufan@ayufan.eu> | 2015-07-08 12:39:03 +0200 |
commit | 638a5f492541fa3f658b4fd3090dda624e4cf4c9 (patch) | |
tree | d152e32eb6cf97e20fd4a905b180176fedd5dc83 /app/models/commit.rb | |
parent | 52cc9a572484a87cea542448e6d439b7c6032e04 (diff) | |
download | gitlab-ci-allow-per-job-failure.tar.gz |
Allow to defined per-job allow_failure parameterallow-per-job-failure
It allows to ignore status of specific job when computed for commit
Diffstat (limited to 'app/models/commit.rb')
-rw-r--r-- | app/models/commit.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/app/models/commit.rb b/app/models/commit.rb index d9774d3..3680220 100644 --- a/app/models/commit.rb +++ b/app/models/commit.rb @@ -111,7 +111,8 @@ class Commit < ActiveRecord::Base name: build_attrs[:name], commands: build_attrs[:script], tag_list: build_attrs[:tags], - options: build_attrs[:options] + options: build_attrs[:options], + allow_failure: build_attrs[:allow_failure] }) end end @@ -149,6 +150,7 @@ class Commit < ActiveRecord::Base commands: build_attrs[:script], tag_list: build_attrs[:tags], options: build_attrs[:options], + allow_failure: build_attrs[:allow_failure], deploy: true }) end @@ -186,7 +188,7 @@ class Commit < ActiveRecord::Base def success? builds_without_retry.all? do |build| - build.success? + build.success? || build.ignored? end end |