2018-05-23 07:55:14 +00:00
|
|
|
require 'spec_helper'
|
|
|
|
|
|
|
|
describe GitlabSchema.types['Project'] do
|
2018-06-25 08:59:00 +00:00
|
|
|
it { expect(described_class).to expose_permissions_using(Types::PermissionTypes::Project) }
|
|
|
|
|
2018-05-23 07:55:14 +00:00
|
|
|
it { expect(described_class.graphql_name).to eq('Project') }
|
2018-06-14 13:06:53 +00:00
|
|
|
|
|
|
|
describe 'nested merge request' do
|
|
|
|
it { expect(described_class).to have_graphql_field(:merge_request) }
|
|
|
|
|
|
|
|
it 'authorizes the merge request' do
|
|
|
|
expect(described_class.fields['mergeRequest'])
|
|
|
|
.to require_graphql_authorizations(:read_merge_request)
|
|
|
|
end
|
|
|
|
end
|
2018-06-26 16:31:05 +00:00
|
|
|
|
|
|
|
it { is_expected.to have_graphql_field(:pipelines) }
|
2018-05-23 07:55:14 +00:00
|
|
|
end
|