summaryrefslogtreecommitdiff
path: root/spec/graphql/types/group_member_type_spec.rb
blob: 389295f3a39e7c7095b3c97f4cdb9e656e30900a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# frozen_string_literal: true

require 'spec_helper'

RSpec.describe Types::GroupMemberType do
  specify { expect(described_class).to expose_permissions_using(Types::PermissionTypes::Group) }

  specify { expect(described_class.graphql_name).to eq('GroupMember') }

  specify { expect(described_class).to require_graphql_authorizations(:read_group) }

  it 'has the expected fields' do
    expected_fields = %w[
      access_level created_by created_at updated_at expires_at group notification_email
    ]

    expect(described_class).to include_graphql_fields(*expected_fields)
  end
end