2018-06-25 08:59:00 +00:00
|
|
|
require 'spec_helper'
|
|
|
|
|
2018-06-26 16:31:05 +00:00
|
|
|
describe GitlabSchema.types['MergeRequest'] do
|
2018-06-25 08:59:00 +00:00
|
|
|
it { expect(described_class).to expose_permissions_using(Types::PermissionTypes::MergeRequest) }
|
2018-06-26 16:31:05 +00:00
|
|
|
|
|
|
|
describe 'head pipeline' do
|
|
|
|
it 'has a head pipeline field' do
|
|
|
|
expect(described_class).to have_graphql_field(:head_pipeline)
|
|
|
|
end
|
|
|
|
|
|
|
|
it 'authorizes the field' do
|
|
|
|
expect(described_class.fields['headPipeline'])
|
|
|
|
.to require_graphql_authorizations(:read_pipeline)
|
|
|
|
end
|
|
|
|
end
|
2018-06-25 08:59:00 +00:00
|
|
|
end
|