Welcome to mirror list, hosted at ThFree Co, Russian Federation.

pipeline_status_enum.rb « ci « types « graphql « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: c8e031e18ead006ed585ea5f54caae6a60670284 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# frozen_string_literal: true

module Types
  module Ci
    class PipelineStatusEnum < BaseEnum
      STATUSES_DESCRIPTION = {
        created: 'Pipeline has been created.',
        waiting_for_resource: 'A resource (for example, a runner) that the pipeline requires to run is unavailable.',
        preparing: 'Pipeline is preparing to run.',
        pending: 'Pipeline has not started running yet.',
        running: 'Pipeline is running.',
        failed: 'At least one stage of the pipeline failed.',
        success: 'Pipeline completed successfully.',
        canceled: 'Pipeline was canceled before completion.',
        skipped: 'Pipeline was skipped.',
        manual: 'Pipeline needs to be manually started.',
        scheduled: 'Pipeline is scheduled to run.'
      }.freeze

      STATUSES_DESCRIPTION.each do |state, description|
        value state.to_s.upcase,
              description: description,
              value: state.to_s
      end
    end
  end
end