2019-10-17 09:07:07 +00:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2018-06-26 16:31:05 +00:00
|
|
|
require 'spec_helper'
|
|
|
|
|
2020-06-24 09:08:32 +00:00
|
|
|
RSpec.describe Types::Ci::PipelineType do
|
2020-05-07 06:09:38 +00:00
|
|
|
specify { expect(described_class.graphql_name).to eq('Pipeline') }
|
2018-06-26 16:31:05 +00:00
|
|
|
|
2020-05-07 06:09:38 +00:00
|
|
|
specify { expect(described_class).to expose_permissions_using(Types::PermissionTypes::Ci::Pipeline) }
|
2020-12-09 18:09:48 +00:00
|
|
|
|
|
|
|
it 'contains attributes related to a pipeline' do
|
|
|
|
expected_fields = %w[
|
2021-05-14 12:10:58 +00:00
|
|
|
id iid sha before_sha complete status detailed_status config_source
|
2021-04-26 18:09:45 +00:00
|
|
|
duration queued_duration
|
2020-12-09 18:09:48 +00:00
|
|
|
coverage created_at updated_at started_at finished_at committed_at
|
2021-11-03 12:10:26 +00:00
|
|
|
stages user retryable cancelable jobs source_job job job_artifacts downstream
|
2021-10-29 15:11:56 +00:00
|
|
|
upstream path project active user_permissions warnings commit commit_path uses_needs
|
2022-06-06 18:09:02 +00:00
|
|
|
test_report_summary test_suite ref ref_path warning_messages merge_request_event_type
|
2020-12-09 18:09:48 +00:00
|
|
|
]
|
|
|
|
|
|
|
|
if Gitlab.ee?
|
2021-09-27 21:09:27 +00:00
|
|
|
expected_fields += %w[security_report_summary security_report_findings code_quality_reports dast_profile]
|
2020-12-09 18:09:48 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
expect(described_class).to have_graphql_fields(*expected_fields)
|
|
|
|
end
|
2018-06-26 16:31:05 +00:00
|
|
|
end
|