Sha256: b57811a0e7f0f5fe9a7f1f8b7dcd43a0874b3cb11082d57a6d3957827e3f114b

Contents?: true

Size: 453 Bytes

Versions: 18

Compression:

Stored size: 453 Bytes

Contents

class UpstreamHelper < ExtensionHelper
  attr_reader :color, :name, :ordinal
  def initialize(extension, params, builder)
    super extension, params, builder

    case params[:status]
    when 'unstable'
      @name = 'UNSTABLE'
      @ordinal = '1'
      @color = 'yellow'
    when 'failed'
      @name = 'FAILURE'
      @ordinal = '2'
      @color = 'RED'
    else
      @name = 'SUCCESS'
      @ordinal = '0'
      @color = 'BLUE'
    end
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
jenkins_pipeline_builder-1.10.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.9.1 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.9.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.8.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.7.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.5.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.3.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.2.1 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.2.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.1.5 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.1.4 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.1.3 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.1.2 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.1.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-1.0.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-0.16.3 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-0.16.2 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb
jenkins_pipeline_builder-0.16.0 lib/jenkins_pipeline_builder/extensions/helpers/triggers/upstream_helper.rb