Sha256: 9d04d772aeb15257e95f5552eed41ca4de0a367ecb43dbd3698293a3d0a563a6
Contents?: true
Size: 528 Bytes
Versions: 1
Compression:
Stored size: 528 Bytes
Contents
module Codestatus class BuildStatus UNDEFINED = 'undefined'.freeze # Defined in GitHub ERROR = 'error'.freeze FAILURE = 'failure'.freeze PENDING = 'pending'.freeze SUCCESS = 'success'.freeze STATUSES = [ ERROR, FAILURE, PENDING, SUCCESS, ].freeze def initialize(sha:, status:) @sha = sha if STATUSES.include?(status.to_s) @status = status.to_s else @status = UNDEFINED end end attr_reader :sha, :status end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
codestatus-0.1.1 | lib/codestatus/build_status.rb |