Commit a75f4bf3 authored by Alex Kalderimis's avatar Alex Kalderimis

Merge branch 'pedropombeiro/356671/graphql-add-alpha-deprecation' into 'master'

GraphQL: Add alpha deprecation reason

See merge request gitlab-org/gitlab!84756
parents 3ca6af6c a3ac5247
......@@ -5,7 +5,7 @@ module Gitlab
class Deprecation
REASONS = {
renamed: 'This was renamed.',
discouraged: 'Use of this is not recommended.'
alpha: 'This feature is in Alpha, and can be removed or changed at any point.'
}.freeze
include ActiveModel::Validations
......
......@@ -62,9 +62,9 @@ RSpec.shared_examples 'Gitlab-style deprecations' do
expect(deprecable.deprecation_reason).to include 'This was renamed.'
end
it 'supports named reasons: discouraged' do
deprecable = subject(deprecated: { milestone: '1.10', reason: :discouraged })
it 'supports named reasons: alpha' do
deprecable = subject(deprecated: { milestone: '1.10', reason: :alpha })
expect(deprecable.deprecation_reason).to include 'Use of this is not recommended.'
expect(deprecable.deprecation_reason).to include 'This feature is in Alpha'
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment