diff options
author | Luke Duncalfe <lduncalfe@eml.cc> | 2019-06-21 16:45:27 +1200 |
---|---|---|
committer | Luke Duncalfe <lduncalfe@eml.cc> | 2019-06-28 12:03:33 +1200 |
commit | 4b9b2a43d02fc5154f780ade7fe76c02420fff15 (patch) | |
tree | 6ada662de1b913c6d265a554d5702c8a68788fae /spec/graphql | |
parent | 62a40c5170cbecfc77dcb5fc97a23f3e93898a53 (diff) | |
download | gitlab-ce-4b9b2a43d02fc5154f780ade7fe76c02420fff15.tar.gz |
GraphQL mutations for add, remove and toggle emoji62826-graphql-emoji-mutations
Adding new `AddAwardEmoji`, `RemoveAwardEmoji` and `ToggleAwardEmoji`
GraphQL mutations.
Adding new `#authorized_find_with_pre_checks!` and (unused, but for
completeness `#authorized_find_with_post_checks!`) authorization
methods. These allow us to perform an authorized find, and run our own
additional checks before or after the authorization runs.
https://gitlab.com/gitlab-org/gitlab-ce/issues/62826
Diffstat (limited to 'spec/graphql')
-rw-r--r-- | spec/graphql/types/award_emojis/award_emoji_type_spec.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/spec/graphql/types/award_emojis/award_emoji_type_spec.rb b/spec/graphql/types/award_emojis/award_emoji_type_spec.rb new file mode 100644 index 00000000000..5663a3d7195 --- /dev/null +++ b/spec/graphql/types/award_emojis/award_emoji_type_spec.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +require 'spec_helper' + +describe GitlabSchema.types['AwardEmoji'] do + it { expect(described_class.graphql_name).to eq('AwardEmoji') } + + it { is_expected.to require_graphql_authorizations(:read_emoji) } + + it { expect(described_class).to have_graphql_fields(:description, :unicode_version, :emoji, :name, :unicode, :user) } +end |