summaryrefslogtreecommitdiff
path: root/app/graphql/types/deployment_status_enum.rb
blob: 7ef69d3f1c131c0cae7ad685d79ae35db9aab8b0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# frozen_string_literal: true

module Types
  class DeploymentStatusEnum < BaseEnum
    graphql_name 'DeploymentStatus'
    description 'All deployment statuses.'

    ::Deployment.statuses.each_key do |status|
      value status.upcase,
            description: "A deployment that is #{status.tr('_', ' ')}.",
            value: status
    end
  end
end