Add latest changes from gitlab-org/gitlab@master

This commit is contained in:
GitLab Bot 2022-06-29 03:08:18 +00:00
parent 2b963521be
commit 7d4e6bdbfb
42 changed files with 170 additions and 935 deletions

View File

@ -382,7 +382,6 @@ Layout/HashAlignment:
- 'ee/lib/gitlab/ci/parsers/security/formatters/dependency_list.rb'
- 'ee/lib/gitlab/elastic/helper.rb'
- 'ee/lib/gitlab/elastic/indexer.rb'
- 'ee/lib/gitlab/geo/replication/base_transfer.rb'
- 'ee/spec/controllers/ee/projects/variables_controller_spec.rb'
- 'ee/spec/controllers/groups/epic_boards_controller_spec.rb'
- 'ee/spec/controllers/groups/issues_controller_spec.rb'
@ -610,7 +609,6 @@ Layout/HashAlignment:
- 'spec/lib/gitlab/etag_caching/router/graphql_spec.rb'
- 'spec/lib/gitlab/git/repository_spec.rb'
- 'spec/lib/gitlab/grape_logging/formatters/lograge_with_timestamp_spec.rb'
- 'spec/lib/gitlab/hook_data/issuable_builder_spec.rb'
- 'spec/lib/gitlab/import_export/attributes_finder_spec.rb'
- 'spec/lib/gitlab/import_export/group/object_builder_spec.rb'
- 'spec/lib/gitlab/import_export/group/relation_tree_restorer_spec.rb'
@ -688,7 +686,6 @@ Layout/HashAlignment:
- 'spec/services/ci/create_pipeline_service/logger_spec.rb'
- 'spec/services/ci/create_pipeline_service/tags_spec.rb'
- 'spec/services/ci/job_artifacts/create_service_spec.rb'
- 'spec/services/ci/retry_build_service_spec.rb'
- 'spec/services/deployments/link_merge_requests_service_spec.rb'
- 'spec/services/discussions/capture_diff_note_positions_service_spec.rb'
- 'spec/services/groups/import_export/import_service_spec.rb'

View File

@ -96,7 +96,6 @@ Layout/MultilineOperationIndentation:
- 'qa/qa/page/component/snippet.rb'
- 'qa/qa/runtime/api/repository_storage_moves.rb'
- 'rubocop/cop/gitlab/keys_first_and_values_first.rb'
- 'rubocop/cop/migration/hash_index.rb'
- 'rubocop/migration_helpers.rb'
- 'spec/frontend/fixtures/tabs.rb'
- 'spec/lib/gitlab/ci/pipeline/seed/build_spec.rb'

View File

@ -141,7 +141,6 @@ Layout/SpaceInLambdaLiteral:
- 'app/serializers/concerns/user_status_tooltip.rb'
- 'app/serializers/container_repository_entity.rb'
- 'app/serializers/container_tag_entity.rb'
- 'app/serializers/deploy_key_entity.rb'
- 'app/serializers/deployment_cluster_entity.rb'
- 'app/serializers/deployment_entity.rb'
- 'app/serializers/detailed_status_entity.rb'
@ -276,7 +275,6 @@ Layout/SpaceInLambdaLiteral:
- 'ee/app/serializers/epic_entity.rb'
- 'ee/app/serializers/epic_note_entity.rb'
- 'ee/app/serializers/linked_epic_issue_entity.rb'
- 'ee/app/serializers/merge_request_compliance_entity.rb'
- 'ee/app/serializers/metrics_report_metric_entity.rb'
- 'ee/app/serializers/vulnerabilities/feedback_entity.rb'
- 'ee/app/serializers/vulnerabilities/finding_entity.rb'

View File

@ -11,7 +11,6 @@ Layout/SpaceInsideBlockBraces:
- 'app/controllers/projects/boards_controller.rb'
- 'app/experiments/security_reports_mr_widget_prompt_experiment.rb'
- 'app/experiments/video_tutorials_continuous_onboarding_experiment.rb'
- 'app/graphql/types/concerns/find_closest.rb'
- 'app/helpers/favicon_helper.rb'
- 'app/helpers/time_zone_helper.rb'
- 'app/helpers/todos_helper.rb'
@ -245,7 +244,6 @@ Layout/SpaceInsideBlockBraces:
- 'ee/spec/support/shared_examples/services/boards/base_service_shared_examples.rb'
- 'ee/spec/support/shared_examples/services/search_notes_shared_examples.rb'
- 'ee/spec/tasks/gitlab/elastic_rake_spec.rb'
- 'ee/spec/uploaders/every_gitlab_uploader_spec.rb'
- 'ee/spec/views/registrations/groups_projects/new.html.haml_spec.rb'
- 'ee/spec/views/shared/billings/_eoa_bronze_plan_banner.html.haml_spec.rb'
- 'ee/spec/views/shared/credentials_inventory/_expiry_date.html.haml_spec.rb'
@ -378,9 +376,7 @@ Layout/SpaceInsideBlockBraces:
- 'spec/frontend/fixtures/pipeline_schedules.rb'
- 'spec/frontend/fixtures/pipelines.rb'
- 'spec/frontend/fixtures/projects.rb'
- 'spec/frontend/fixtures/prometheus_service.rb'
- 'spec/frontend/fixtures/raw.rb'
- 'spec/frontend/fixtures/services.rb'
- 'spec/frontend/fixtures/snippet.rb'
- 'spec/frontend/fixtures/todos.rb'
- 'spec/graphql/mutations/merge_requests/set_labels_spec.rb'
@ -604,7 +600,6 @@ Layout/SpaceInsideBlockBraces:
- 'spec/presenters/packages/composer/packages_presenter_spec.rb'
- 'spec/presenters/packages/conan/package_presenter_spec.rb'
- 'spec/presenters/packages/nuget/packages_metadata_presenter_spec.rb'
- 'spec/presenters/packages/pypi/package_presenter_spec.rb'
- 'spec/presenters/project_presenter_spec.rb'
- 'spec/requests/api/branches_spec.rb'
- 'spec/requests/api/ci/jobs_spec.rb'
@ -659,7 +654,6 @@ Layout/SpaceInsideBlockBraces:
- 'spec/requests/oauth/tokens_controller_spec.rb'
- 'spec/rubocop/cop/migration/create_table_with_foreign_keys_spec.rb'
- 'spec/serializers/cluster_entity_spec.rb'
- 'spec/serializers/deploy_key_entity_spec.rb'
- 'spec/serializers/import/provider_repo_serializer_spec.rb'
- 'spec/services/auto_merge/base_service_spec.rb'
- 'spec/services/auto_merge_service_spec.rb'
@ -762,4 +756,3 @@ Layout/SpaceInsideBlockBraces:
- 'spec/workers/pages_worker_spec.rb'
- 'spec/workers/purge_dependency_proxy_cache_worker_spec.rb'
- 'spec/workers/releases/manage_evidence_worker_spec.rb'
- 'spec/workers/repository_remove_remote_worker_spec.rb'

View File

@ -71,7 +71,6 @@ Layout/SpaceInsideParens:
- 'ee/spec/features/merge_requests/user_resets_approvers_spec.rb'
- 'ee/spec/features/merge_requests/user_views_all_merge_requests_spec.rb'
- 'ee/spec/features/merge_trains/two_merge_requests_on_train_spec.rb'
- 'ee/spec/finders/ee/alert_management/alerts_finder_spec.rb'
- 'ee/spec/finders/ee/alert_management/http_integrations_finder_spec.rb'
- 'ee/spec/finders/epics_finder_spec.rb'
- 'ee/spec/finders/security/pipeline_vulnerabilities_finder_spec.rb'
@ -89,7 +88,6 @@ Layout/SpaceInsideParens:
- 'ee/spec/lib/gitlab/auth/group_saml/group_lookup_spec.rb'
- 'ee/spec/lib/gitlab/auth/otp/session_enforcer_spec.rb'
- 'ee/spec/lib/gitlab/auth/smartcard/ldap_certificate_spec.rb'
- 'ee/spec/lib/gitlab/auth_spec.rb'
- 'ee/spec/lib/gitlab/ci/templates/coverage_fuzzing_gitlab_ci_yaml_spec.rb'
- 'ee/spec/lib/gitlab/ci/templates/dast_api_gitlab_ci_yaml_spec.rb'
- 'ee/spec/lib/gitlab/ci/templates/dast_api_latest_gitlab_ci_yaml_spec.rb'
@ -228,9 +226,7 @@ Layout/SpaceInsideParens:
- 'spec/frontend/fixtures/pipeline_schedules.rb'
- 'spec/frontend/fixtures/pipelines.rb'
- 'spec/frontend/fixtures/projects.rb'
- 'spec/frontend/fixtures/prometheus_service.rb'
- 'spec/frontend/fixtures/raw.rb'
- 'spec/frontend/fixtures/services.rb'
- 'spec/frontend/fixtures/snippet.rb'
- 'spec/frontend/fixtures/todos.rb'
- 'spec/graphql/mutations/todos/restore_many_spec.rb'
@ -281,7 +277,6 @@ Layout/SpaceInsideParens:
- 'spec/lib/gitlab/ci/templates/auto_devops_gitlab_ci_yaml_spec.rb'
- 'spec/lib/gitlab/ci/templates/flutter_gitlab_ci_yaml_spec.rb'
- 'spec/lib/gitlab/ci/templates/kaniko_gitlab_ci_yaml_spec.rb'
- 'spec/lib/gitlab/ci/templates/managed_cluster_applications_gitlab_ci_yaml_spec.rb'
- 'spec/lib/gitlab/ci/templates/npm_spec.rb'
- 'spec/lib/gitlab/ci/templates/terraform_gitlab_ci_yaml_spec.rb'
- 'spec/lib/gitlab/ci/templates/terraform_latest_gitlab_ci_yaml_spec.rb'
@ -387,8 +382,6 @@ Layout/SpaceInsideParens:
- 'spec/requests/search_controller_spec.rb'
- 'spec/serializers/analytics_build_entity_spec.rb'
- 'spec/serializers/merge_request_user_entity_spec.rb'
- 'spec/services/authorized_project_update/project_create_service_spec.rb'
- 'spec/services/authorized_project_update/project_group_link_create_service_spec.rb'
- 'spec/services/boards/issues/list_service_spec.rb'
- 'spec/services/ci/compare_test_reports_service_spec.rb'
- 'spec/services/ci/pipeline_processing/atomic_processing_service/status_collection_spec.rb'

View File

@ -44,7 +44,6 @@ Lint/RedundantCopDisableDirective:
- 'app/workers/bulk_imports/entity_worker.rb'
- 'app/workers/container_expiration_policy_worker.rb'
- 'app/workers/create_note_diff_file_worker.rb'
- 'app/workers/expire_job_cache_worker.rb'
- 'app/workers/import_issues_csv_worker.rb'
- 'app/workers/incident_management/process_alert_worker_v2.rb'
- 'app/workers/merge_worker.rb'
@ -152,7 +151,6 @@ Lint/RedundantCopDisableDirective:
- 'lib/gitlab/profiler.rb'
- 'lib/gitlab/project_search_results.rb'
- 'lib/gitlab/redis/hll.rb'
- 'lib/gitlab/request_profiler.rb'
- 'lib/gitlab/slash_commands/issue_search.rb'
- 'lib/gitlab/usage_data.rb'
- 'lib/gitlab/usage_data_queries.rb'

View File

@ -57,7 +57,6 @@ Migration/BackgroundMigrationBaseClass:
- 'lib/gitlab/background_migration/migrate_project_taggings_context_from_tags_to_topics.rb'
- 'lib/gitlab/background_migration/migrate_requirements_to_work_items.rb'
- 'lib/gitlab/background_migration/migrate_shimo_confluence_integration_category.rb'
- 'lib/gitlab/background_migration/migrate_stage_status.rb'
- 'lib/gitlab/background_migration/migrate_u2f_webauthn.rb'
- 'lib/gitlab/background_migration/move_container_registry_enabled_to_project_feature.rb'
- 'lib/gitlab/background_migration/nullify_orphan_runner_id_on_ci_builds.rb'

View File

@ -116,9 +116,6 @@ Naming/RescuedExceptionsVariableName:
- 'ee/app/services/geo/repository_base_sync_service.rb'
- 'ee/app/services/incident_management/oncall_rotations/create_service.rb'
- 'ee/app/services/incident_management/oncall_rotations/edit_service.rb'
- 'ee/app/services/namespaces/deactivate_members_over_limit_service.rb'
- 'ee/app/services/namespaces/remove_project_group_links_outside_hierarchy_service.rb'
- 'ee/app/services/namespaces/update_prevent_sharing_outside_hierarchy_service.rb'
- 'ee/app/services/projects/licenses/create_policy_service.rb'
- 'ee/app/services/projects/licenses/update_policy_service.rb'
- 'ee/app/services/security/ingestion/ingest_report_service.rb'
@ -132,7 +129,6 @@ Naming/RescuedExceptionsVariableName:
- 'ee/app/workers/geo/file_removal_worker.rb'
- 'ee/app/workers/geo/repositories_clean_up_worker.rb'
- 'ee/app/workers/geo/scheduler/scheduler_worker.rb'
- 'ee/app/workers/namespaces/free_user_cap_worker.rb'
- 'ee/app/workers/refresh_license_compliance_checks_worker.rb'
- 'ee/app/workers/repository_update_mirror_worker.rb'
- 'ee/app/workers/sync_seat_link_request_worker.rb'

View File

@ -103,7 +103,6 @@ Rails/FilePath:
- 'spec/features/projects/snippets/create_snippet_spec.rb'
- 'spec/features/projects/tags/user_edits_tags_spec.rb'
- 'spec/features/projects/tree/upload_file_spec.rb'
- 'spec/features/refactor_blob_viewer_disabled/projects/files/user_replaces_files_spec.rb'
- 'spec/features/snippets/user_creates_snippet_spec.rb'
- 'spec/features/snippets/user_edits_snippet_spec.rb'
- 'spec/features/uploads/user_uploads_avatar_to_group_spec.rb'

View File

@ -82,4 +82,3 @@ Rails/HelperInstanceVariable:
- 'ee/app/helpers/ee/wiki_helper.rb'
- 'ee/app/helpers/path_locks_helper.rb'
- 'ee/app/helpers/projects/security/discover_helper.rb'
- 'ee/app/helpers/seats_count_alert_helper.rb'

View File

@ -544,7 +544,6 @@ Rails/SkipsModelValidations:
- 'spec/lib/gitlab/middleware/go_spec.rb'
- 'spec/lib/gitlab/middleware/query_analyzer_spec.rb'
- 'spec/lib/gitlab/object_hierarchy_spec.rb'
- 'spec/lib/gitlab/pages_transfer_spec.rb'
- 'spec/lib/gitlab/sidekiq_middleware/query_analyzer_spec.rb'
- 'spec/lib/sidebars/projects/menus/project_information_menu_spec.rb'
- 'spec/mailers/notify_spec.rb'

View File

@ -347,7 +347,6 @@ RSpec/AnyInstanceOf:
- spec/services/ci/list_config_variables_service_spec.rb
- spec/services/ci/register_job_service_spec.rb
- spec/services/ci/resource_groups/assign_resource_from_resource_group_service_spec.rb
- spec/services/ci/retry_build_service_spec.rb
- spec/services/ci/retry_pipeline_service_spec.rb
- spec/services/ci/stop_environments_service_spec.rb
- spec/services/clusters/applications/create_service_spec.rb
@ -481,7 +480,6 @@ RSpec/AnyInstanceOf:
- spec/workers/email_receiver_worker_spec.rb
- spec/workers/emails_on_push_worker_spec.rb
- spec/workers/error_tracking_issue_link_worker_spec.rb
- spec/workers/expire_pipeline_cache_worker_spec.rb
- spec/workers/group_export_worker_spec.rb
- spec/workers/group_import_worker_spec.rb
- spec/workers/namespaces/root_statistics_worker_spec.rb

View File

@ -233,7 +233,6 @@ RSpec/ContextWording:
- 'ee/spec/finders/dast_scanner_profiles_finder_spec.rb'
- 'ee/spec/finders/dast_site_profiles_finder_spec.rb'
- 'ee/spec/finders/dast_site_validations_finder_spec.rb'
- 'ee/spec/finders/ee/alert_management/alerts_finder_spec.rb'
- 'ee/spec/finders/ee/alert_management/http_integrations_finder_spec.rb'
- 'ee/spec/finders/ee/clusters/agent_authorizations_finder_spec.rb'
- 'ee/spec/finders/ee/group_members_finder_spec.rb'
@ -487,11 +486,6 @@ RSpec/ContextWording:
- 'ee/spec/lib/gitlab/geo/log_helpers_spec.rb'
- 'ee/spec/lib/gitlab/geo/oauth/session_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/blob_downloader_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/file_downloader_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/file_retriever_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/file_transfer_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/job_artifact_downloader_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/job_artifact_transfer_spec.rb'
- 'ee/spec/lib/gitlab/geo/replicator_spec.rb'
- 'ee/spec/lib/gitlab/geo/signed_data_spec.rb'
- 'ee/spec/lib/gitlab/geo_spec.rb'
@ -908,8 +902,6 @@ RSpec/ContextWording:
- 'ee/spec/services/ee/protected_branches/create_service_spec.rb'
- 'ee/spec/services/ee/quick_actions/target_service_spec.rb'
- 'ee/spec/services/ee/resource_events/merge_into_notes_service_spec.rb'
- 'ee/spec/services/ee/service_ping/build_payload_service_spec.rb'
- 'ee/spec/services/ee/service_ping/permit_data_categories_service_spec.rb'
- 'ee/spec/services/ee/users/build_service_spec.rb'
- 'ee/spec/services/ee/users/create_service_spec.rb'
- 'ee/spec/services/ee/users/destroy_service_spec.rb'
@ -936,9 +928,7 @@ RSpec/ContextWording:
- 'ee/spec/services/geo/container_repository_sync_service_spec.rb'
- 'ee/spec/services/geo/container_repository_sync_spec.rb'
- 'ee/spec/services/geo/design_repository_sync_service_spec.rb'
- 'ee/spec/services/geo/file_download_service_spec.rb'
- 'ee/spec/services/geo/file_registry_removal_service_spec.rb'
- 'ee/spec/services/geo/file_upload_service_spec.rb'
- 'ee/spec/services/geo/framework_repository_sync_service_spec.rb'
- 'ee/spec/services/geo/hashed_storage_migration_service_spec.rb'
- 'ee/spec/services/geo/move_repository_service_spec.rb'
@ -1113,7 +1103,6 @@ RSpec/ContextWording:
- 'ee/spec/tasks/gitlab/elastic_rake_spec.rb'
- 'ee/spec/tasks/gitlab/license_rake_spec.rb'
- 'ee/spec/tasks/gitlab/uploads/migrate_rake_spec.rb'
- 'ee/spec/uploaders/every_gitlab_uploader_spec.rb'
- 'ee/spec/views/admin/application_settings/_elasticsearch_form.html.haml_spec.rb'
- 'ee/spec/views/admin/users/show.html.haml_spec.rb'
- 'ee/spec/views/compliance_management/compliance_framework/_project_settings.html.haml_spec.rb'
@ -1160,7 +1149,6 @@ RSpec/ContextWording:
- 'ee/spec/workers/elastic_index_bulk_cron_worker_spec.rb'
- 'ee/spec/workers/elastic_indexing_control_worker_spec.rb'
- 'ee/spec/workers/geo/create_repository_updated_event_worker_spec.rb'
- 'ee/spec/workers/geo/file_download_dispatch_worker_spec.rb'
- 'ee/spec/workers/geo/prune_event_log_worker_spec.rb'
- 'ee/spec/workers/geo/repository_shard_sync_worker_spec.rb'
- 'ee/spec/workers/geo/repository_sync_worker_spec.rb'
@ -1178,7 +1166,6 @@ RSpec/ContextWording:
- 'ee/spec/workers/post_receive_spec.rb'
- 'ee/spec/workers/project_import_schedule_worker_spec.rb'
- 'ee/spec/workers/requirements_management/process_requirements_reports_worker_spec.rb'
- 'ee/spec/workers/security/generate_scan_finding_rules_worker_spec.rb'
- 'ee/spec/workers/security/track_secure_scans_worker_spec.rb'
- 'ee/spec/workers/store_security_reports_worker_spec.rb'
- 'ee/spec/workers/sync_seat_link_request_worker_spec.rb'
@ -2239,7 +2226,6 @@ RSpec/ContextWording:
- 'spec/lib/gitlab/database_spec.rb'
- 'spec/lib/gitlab/default_branch_spec.rb'
- 'spec/lib/gitlab/deploy_key_access_spec.rb'
- 'spec/lib/gitlab/diff/custom_diff_spec.rb'
- 'spec/lib/gitlab/diff/file_collection/merge_request_diff_batch_spec.rb'
- 'spec/lib/gitlab/diff/file_spec.rb'
- 'spec/lib/gitlab/diff/formatters/text_formatter_spec.rb'
@ -2894,7 +2880,6 @@ RSpec/ContextWording:
- 'spec/presenters/packages/conan/package_presenter_spec.rb'
- 'spec/presenters/packages/npm/package_presenter_spec.rb'
- 'spec/presenters/packages/nuget/service_index_presenter_spec.rb'
- 'spec/presenters/packages/pypi/package_presenter_spec.rb'
- 'spec/presenters/project_member_presenter_spec.rb'
- 'spec/presenters/project_presenter_spec.rb'
- 'spec/presenters/projects/import_export/project_export_presenter_spec.rb'
@ -3168,7 +3153,6 @@ RSpec/ContextWording:
- 'spec/serializers/cluster_application_entity_spec.rb'
- 'spec/serializers/cluster_entity_spec.rb'
- 'spec/serializers/context_commits_diff_entity_spec.rb'
- 'spec/serializers/deploy_key_entity_spec.rb'
- 'spec/serializers/diff_file_base_entity_spec.rb'
- 'spec/serializers/diff_file_entity_spec.rb'
- 'spec/serializers/diff_file_metadata_entity_spec.rb'
@ -3483,7 +3467,6 @@ RSpec/ContextWording:
- 'spec/services/projects/update_remote_mirror_service_spec.rb'
- 'spec/services/projects/update_repository_storage_service_spec.rb'
- 'spec/services/projects/update_service_spec.rb'
- 'spec/services/prometheus/create_default_alerts_service_spec.rb'
- 'spec/services/prometheus/proxy_service_spec.rb'
- 'spec/services/prometheus/proxy_variable_substitution_service_spec.rb'
- 'spec/services/protected_tags/create_service_spec.rb'
@ -3883,11 +3866,9 @@ RSpec/ContextWording:
- 'spec/workers/deployments/update_environment_worker_spec.rb'
- 'spec/workers/design_management/new_version_worker_spec.rb'
- 'spec/workers/every_sidekiq_worker_spec.rb'
- 'spec/workers/expire_build_instance_artifacts_worker_spec.rb'
- 'spec/workers/group_import_worker_spec.rb'
- 'spec/workers/incident_management/process_alert_worker_v2_spec.rb'
- 'spec/workers/integrations/create_external_cross_reference_worker_spec.rb'
- 'spec/workers/issue_placement_worker_spec.rb'
- 'spec/workers/issues/placement_worker_spec.rb'
- 'spec/workers/merge_requests/delete_source_branch_worker_spec.rb'
- 'spec/workers/metrics/dashboard/prune_old_annotations_worker_spec.rb'
@ -3902,7 +3883,6 @@ RSpec/ContextWording:
- 'spec/workers/projects/git_garbage_collect_worker_spec.rb'
- 'spec/workers/projects/post_creation_worker_spec.rb'
- 'spec/workers/projects/refresh_build_artifacts_size_statistics_worker_spec.rb'
- 'spec/workers/prometheus/create_default_alerts_worker_spec.rb'
- 'spec/workers/purge_dependency_proxy_cache_worker_spec.rb'
- 'spec/workers/remove_expired_group_links_worker_spec.rb'
- 'spec/workers/remove_expired_members_worker_spec.rb'

View File

@ -181,7 +181,6 @@ RSpec/ExpectChange:
- 'ee/spec/services/external_status_checks/destroy_service_spec.rb'
- 'ee/spec/services/external_status_checks/update_service_spec.rb'
- 'ee/spec/services/geo/blob_download_service_spec.rb'
- 'ee/spec/services/geo/file_download_service_spec.rb'
- 'ee/spec/services/geo/metrics_update_service_spec.rb'
- 'ee/spec/services/geo/project_housekeeping_service_spec.rb'
- 'ee/spec/services/geo/registry_consistency_service_spec.rb'
@ -190,7 +189,6 @@ RSpec/ExpectChange:
- 'ee/spec/services/group_saml/identity/destroy_service_spec.rb'
- 'ee/spec/services/group_saml/sign_up_service_spec.rb'
- 'ee/spec/services/groups/mark_for_deletion_service_spec.rb'
- 'ee/spec/services/groups/recent_merge_requests_count_service_spec.rb'
- 'ee/spec/services/groups/restore_service_spec.rb'
- 'ee/spec/services/groups/sync_service_spec.rb'
- 'ee/spec/services/incident_management/oncall_rotations/edit_service_spec.rb'
@ -201,7 +199,6 @@ RSpec/ExpectChange:
- 'ee/spec/services/lfs/unlock_file_service_spec.rb'
- 'ee/spec/services/merge_request_approval_settings/update_service_spec.rb'
- 'ee/spec/services/merge_requests/update_blocks_service_spec.rb'
- 'ee/spec/services/namespaces/update_prevent_sharing_outside_hierarchy_service_spec.rb'
- 'ee/spec/services/projects/import_service_spec.rb'
- 'ee/spec/services/projects/mark_for_deletion_service_spec.rb'
- 'ee/spec/services/projects/restore_service_spec.rb'
@ -242,7 +239,6 @@ RSpec/ExpectChange:
- 'ee/spec/workers/elastic_remove_expired_namespace_subscriptions_from_index_cron_worker_spec.rb'
- 'ee/spec/workers/geo/verification_state_backfill_service_spec.rb'
- 'ee/spec/workers/new_epic_worker_spec.rb'
- 'ee/spec/workers/security/generate_scan_finding_rules_worker_spec.rb'
- 'ee/spec/workers/store_security_reports_worker_spec.rb'
- 'spec/controllers/admin/clusters_controller_spec.rb'
- 'spec/controllers/admin/groups_controller_spec.rb'

View File

@ -42,7 +42,6 @@ RSpec/ExpectInHook:
- 'ee/spec/lib/gitlab/ci/minutes/cost_factor_spec.rb'
- 'ee/spec/lib/gitlab/code_owners/validator_spec.rb'
- 'ee/spec/lib/gitlab/code_owners_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/job_artifact_retriever_spec.rb'
- 'ee/spec/lib/gitlab/geo_spec.rb'
- 'ee/spec/lib/gitlab/git_access_spec.rb'
- 'ee/spec/lib/gitlab/graphql/aggregations/epics/lazy_epic_aggregate_spec.rb'
@ -448,7 +447,6 @@ RSpec/ExpectInHook:
- 'spec/services/packages/update_package_file_service_spec.rb'
- 'spec/services/pages/zip_directory_service_spec.rb'
- 'spec/services/pages_domains/obtain_lets_encrypt_certificate_service_spec.rb'
- 'spec/services/projects/after_import_service_spec.rb'
- 'spec/services/projects/after_rename_service_spec.rb'
- 'spec/services/projects/branches_by_mode_service_spec.rb'
- 'spec/services/projects/container_repository/cleanup_tags_service_spec.rb'
@ -456,7 +454,6 @@ RSpec/ExpectInHook:
- 'spec/services/projects/container_repository/gitlab/delete_tags_service_spec.rb'
- 'spec/services/projects/container_repository/third_party/delete_tags_service_spec.rb'
- 'spec/services/projects/create_from_template_service_spec.rb'
- 'spec/services/projects/destroy_rollback_service_spec.rb'
- 'spec/services/projects/destroy_service_spec.rb'
- 'spec/services/projects/import_export/export_service_spec.rb'
- 'spec/services/projects/import_service_spec.rb'
@ -471,7 +468,6 @@ RSpec/ExpectInHook:
- 'spec/services/protected_branches/create_service_spec.rb'
- 'spec/services/protected_branches/destroy_service_spec.rb'
- 'spec/services/protected_branches/update_service_spec.rb'
- 'spec/services/repositories/destroy_rollback_service_spec.rb'
- 'spec/services/repositories/destroy_service_spec.rb'
- 'spec/services/search_service_spec.rb'
- 'spec/services/serverless/associate_domain_service_spec.rb'

View File

@ -72,7 +72,6 @@ RSpec/InstanceVariable:
- qa/qa/specs/features/ee/browser_ui/2_plan/multiple_assignees_for_issues/more_than_four_assignees_spec.rb
- qa/qa/specs/features/ee/browser_ui/3_create/repository/code_owners_spec.rb
- qa/qa/specs/features/ee/browser_ui/3_create/repository/push_rules_spec.rb
- qa/qa/specs/features/ee/browser_ui/4_verify/cancelling_merge_request_in_merge_train_spec.rb
- qa/spec/support/repeater_spec.rb
- spec/commands/metrics_server/metrics_server_spec.rb
- spec/controllers/admin/clusters_controller_spec.rb

View File

@ -32,8 +32,6 @@ RSpec/PredicateMatcher:
- 'ee/spec/lib/gitlab/email/handler/create_note_handler_spec.rb'
- 'ee/spec/lib/gitlab/geo/geo_node_status_check_spec.rb'
- 'ee/spec/lib/gitlab/geo/jwt_request_decoder_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/base_transfer_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/file_transfer_spec.rb'
- 'ee/spec/lib/gitlab/geo/replicator_spec.rb'
- 'ee/spec/lib/gitlab/geo_spec.rb'
- 'ee/spec/lib/gitlab/mirror_spec.rb'
@ -72,7 +70,6 @@ RSpec/PredicateMatcher:
- 'ee/spec/models/project_spec.rb'
- 'ee/spec/models/saml_provider_spec.rb'
- 'ee/spec/models/security/orchestration_policy_configuration_spec.rb'
- 'ee/spec/presenters/ci/minutes/quota_presenter_spec.rb'
- 'ee/spec/requests/api/boards_spec.rb'
- 'ee/spec/requests/api/graphql/mutations/epics/set_subscription_spec.rb'
- 'ee/spec/requests/api/groups_spec.rb'
@ -250,7 +247,6 @@ RSpec/PredicateMatcher:
- 'spec/lib/gitlab/dependency_linker/podspec_linker_spec.rb'
- 'spec/lib/gitlab/dependency_linker/requirements_txt_linker_spec.rb'
- 'spec/lib/gitlab/deploy_key_access_spec.rb'
- 'spec/lib/gitlab/diff/custom_diff_spec.rb'
- 'spec/lib/gitlab/diff/file_spec.rb'
- 'spec/lib/gitlab/diff/position_spec.rb'
- 'spec/lib/gitlab/diff/rendered/notebook/diff_file_spec.rb'
@ -458,7 +454,6 @@ RSpec/PredicateMatcher:
- 'spec/services/projects/after_rename_service_spec.rb'
- 'spec/services/projects/cleanup_service_spec.rb'
- 'spec/services/projects/create_service_spec.rb'
- 'spec/services/projects/destroy_rollback_service_spec.rb'
- 'spec/services/projects/destroy_service_spec.rb'
- 'spec/services/projects/fork_service_spec.rb'
- 'spec/services/projects/hashed_storage/base_attachment_service_spec.rb'
@ -471,7 +466,6 @@ RSpec/PredicateMatcher:
- 'spec/services/projects/update_pages_service_spec.rb'
- 'spec/services/projects/update_service_spec.rb'
- 'spec/services/releases/create_service_spec.rb'
- 'spec/services/repositories/destroy_rollback_service_spec.rb'
- 'spec/services/repositories/destroy_service_spec.rb'
- 'spec/services/repository_archive_clean_up_service_spec.rb'
- 'spec/services/resource_access_tokens/revoke_service_spec.rb'
@ -506,7 +500,6 @@ RSpec/PredicateMatcher:
- 'spec/workers/ci/delete_objects_worker_spec.rb'
- 'spec/workers/concerns/worker_attributes_spec.rb'
- 'spec/workers/container_expiration_policies/cleanup_container_repository_worker_spec.rb'
- 'spec/workers/expire_build_instance_artifacts_worker_spec.rb'
- 'spec/workers/group_destroy_worker_spec.rb'
- 'spec/workers/hashed_storage/migrator_worker_spec.rb'
- 'spec/workers/hashed_storage/rollbacker_worker_spec.rb'

View File

@ -45,8 +45,6 @@ RSpec/ReturnFromStub:
- 'ee/spec/lib/gitlab/code_owners_spec.rb'
- 'ee/spec/lib/gitlab/geo/health_check_spec.rb'
- 'ee/spec/lib/gitlab/geo/logger_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/base_transfer_spec.rb'
- 'ee/spec/lib/gitlab/geo/replication/file_transfer_spec.rb'
- 'ee/spec/lib/gitlab/geo_spec.rb'
- 'ee/spec/lib/gitlab/git_access_spec.rb'
- 'ee/spec/lib/gitlab/git_access_wiki_spec.rb'
@ -71,7 +69,6 @@ RSpec/ReturnFromStub:
- 'ee/spec/services/geo/design_repository_sync_service_spec.rb'
- 'ee/spec/services/geo/files_expire_service_spec.rb'
- 'ee/spec/services/geo/framework_repository_sync_service_spec.rb'
- 'ee/spec/services/geo/job_artifact_deleted_event_store_spec.rb'
- 'ee/spec/services/geo/project_housekeeping_service_spec.rb'
- 'ee/spec/services/geo/repository_base_sync_service_spec.rb'
- 'ee/spec/services/geo/repository_updated_service_spec.rb'
@ -81,7 +78,6 @@ RSpec/ReturnFromStub:
- 'ee/spec/services/merge_requests/build_service_spec.rb'
- 'ee/spec/services/merge_trains/create_pipeline_service_spec.rb'
- 'ee/spec/services/merge_trains/refresh_merge_request_service_spec.rb'
- 'ee/spec/services/network_policies/resources_service_spec.rb'
- 'ee/spec/services/projects/hashed_storage/migrate_repository_service_spec.rb'
- 'ee/spec/services/security/token_revocation_service_spec.rb'
- 'ee/spec/services/system_notes/merge_train_service_spec.rb'
@ -99,7 +95,6 @@ RSpec/ReturnFromStub:
- 'ee/spec/workers/ee/ci/build_finished_worker_spec.rb'
- 'ee/spec/workers/geo/container_repository_sync_dispatch_worker_spec.rb'
- 'ee/spec/workers/geo/design_repository_shard_sync_worker_spec.rb'
- 'ee/spec/workers/geo/file_download_dispatch_worker_spec.rb'
- 'ee/spec/workers/geo/repository_shard_sync_worker_spec.rb'
- 'ee/spec/workers/geo/repository_verification/primary/shard_worker_spec.rb'
- 'ee/spec/workers/geo/repository_verification/primary/single_worker_spec.rb'

View File

@ -42,7 +42,6 @@ RSpec/ScatteredLet:
- 'ee/spec/models/approval_wrapped_any_approver_rule_spec.rb'
- 'ee/spec/models/approvals/scan_finding_wrapped_rule_set_spec.rb'
- 'ee/spec/models/ci/minutes/notification_spec.rb'
- 'ee/spec/models/ci/minutes/quota_spec.rb'
- 'ee/spec/models/ci/pipeline_spec.rb'
- 'ee/spec/models/ee/ci/build_dependencies_spec.rb'
- 'ee/spec/models/ee/namespace/root_storage_size_spec.rb'

View File

@ -222,7 +222,7 @@ export default {
/>
<gl-button
v-else-if="isRetryable"
icon="repeat"
icon="retry"
:title="$options.ACTIONS_RETRY"
:aria-label="$options.ACTIONS_RETRY"
:method="currentJobMethod"

View File

@ -10,6 +10,8 @@ export default {
},
components: {
PipelineMiniGraph,
LinkedPipelinesMiniList: () =>
import('ee_component/vue_shared/components/linked_pipelines_mini_list.vue'),
},
inject: ['projectFullPath'],
props: {
@ -45,6 +47,9 @@ export default {
downstreamPipelines() {
return this.linkedPipelines?.downstream?.nodes || [];
},
hasDownstreamPipelines() {
return this.downstreamPipelines.length > 0;
},
hasPipelineStages() {
return this.pipelineStages.length > 0;
},
@ -82,11 +87,23 @@ export default {
</script>
<template>
<pipeline-mini-graph
<div
v-if="hasPipelineStages"
:downstream-pipelines="downstreamPipelines"
:pipeline-path="pipelinePath"
:stages="pipelineStages"
:upstream-pipeline="upstreamPipeline"
/>
class="gl-align-items-center gl-display-inline-flex gl-flex-wrap stage-cell gl-mr-5"
>
<linked-pipelines-mini-list
v-if="upstreamPipeline"
:triggered-by="/* eslint-disable @gitlab/vue-no-new-non-primitive-in-template */ [
upstreamPipeline,
] /* eslint-enable @gitlab/vue-no-new-non-primitive-in-template */"
data-testid="pipeline-editor-mini-graph-upstream"
/>
<pipeline-mini-graph :stages="pipelineStages" />
<linked-pipelines-mini-list
v-if="hasDownstreamPipelines"
:triggered="downstreamPipelines"
:pipeline-path="pipelinePath"
data-testid="pipeline-editor-mini-graph-downstream"
/>
</div>
</template>

View File

@ -174,7 +174,7 @@ export default {
<div class="gl-display-flex gl-flex-wrap">
<pipeline-editor-mini-graph :pipeline="pipeline" v-on="$listeners" />
<gl-button
class="gl-ml-3"
class="gl-mt-2 gl-md-mt-0"
category="secondary"
variant="confirm"
:href="status.detailsPath"

View File

@ -96,7 +96,7 @@ export default {
<template #cell(actions)="{ item }">
<gl-button
v-if="canRetryJob(item)"
icon="repeat"
icon="retry"
:title="$options.retry"
:aria-label="$options.retry"
@click="retryJob(item.id)"

View File

@ -1,59 +1,31 @@
<script>
import { GlIcon } from '@gitlab/ui';
import PipelineStages from '~/pipelines/components/pipelines_list/pipeline_stages.vue';
import PipelineStage from '~/pipelines/components/pipelines_list/pipeline_stage.vue';
/**
* Renders the pipeline mini graph.
*/
export default {
components: {
GlIcon,
PipelineStages,
LinkedPipelinesMiniList: () =>
import('ee_component/vue_shared/components/linked_pipelines_mini_list.vue'),
PipelineStage,
},
arrowStyles: [
'arrow-icon gl-display-inline-block gl-mx-1 gl-text-gray-500 gl-vertical-align-middle!',
],
props: {
downstreamPipelines: {
type: Array,
required: false,
default: () => [],
},
isMergeTrain: {
type: Boolean,
required: false,
default: false,
},
pipelinePath: {
type: String,
required: false,
default: '',
},
stages: {
type: Array,
required: true,
default: () => [],
},
stagesClass: {
type: [Array, Object, String],
required: false,
default: '',
},
updateDropdown: {
type: Boolean,
required: false,
default: false,
},
upstreamPipeline: {
type: Object,
stagesClass: {
type: [Array, Object, String],
required: false,
default: () => {},
default: '',
},
},
computed: {
hasDownstreamPipelines() {
return Boolean(this.downstreamPipelines.length);
isMergeTrain: {
type: Boolean,
required: false,
default: false,
},
},
methods: {
@ -64,39 +36,19 @@ export default {
};
</script>
<template>
<div class="stage-cell" data-testid="pipeline-mini-graph">
<linked-pipelines-mini-list
v-if="upstreamPipeline"
:triggered-by="/* eslint-disable @gitlab/vue-no-new-non-primitive-in-template */ [
upstreamPipeline,
] /* eslint-enable @gitlab/vue-no-new-non-primitive-in-template */"
data-testid="pipeline-mini-graph-upstream"
/>
<gl-icon
v-if="upstreamPipeline"
:class="$options.arrowStyles"
name="long-arrow"
data-testid="upstream-arrow-icon"
/>
<pipeline-stages
:is-merge-train="isMergeTrain"
:stages="stages"
:update-dropdown="updateDropdown"
:stages-class="stagesClass"
data-testid="pipeline-stages"
@pipelineActionRequestComplete="onPipelineActionRequestComplete"
/>
<gl-icon
v-if="hasDownstreamPipelines"
:class="$options.arrowStyles"
name="long-arrow"
data-testid="downstream-arrow-icon"
/>
<linked-pipelines-mini-list
v-if="hasDownstreamPipelines"
:triggered="downstreamPipelines"
:pipeline-path="pipelinePath"
data-testid="pipeline-mini-graph-downstream"
/>
<div data-testid="pipeline-mini-graph" class="gl-display-inline gl-vertical-align-middle">
<div
v-for="stage in stages"
:key="stage.name"
:class="stagesClass"
class="dropdown gl-display-inline-block gl-mr-2 gl-my-2 gl-vertical-align-middle stage-container"
>
<pipeline-stage
:stage="stage"
:update-dropdown="updateDropdown"
:is-merge-train="isMergeTrain"
@pipelineActionRequestComplete="onPipelineActionRequestComplete"
/>
</div>
</div>
</template>

View File

@ -80,7 +80,7 @@ export default {
class="js-pipelines-retry-button"
data-qa-selector="pipeline_retry_button"
data-testid="pipelines-retry-button"
icon="repeat"
icon="retry"
variant="default"
category="secondary"
@click="handleRetryClick"

View File

@ -1,54 +0,0 @@
<script>
import PipelineStage from '~/pipelines/components/pipelines_list/pipeline_stage.vue';
/**
* Renders the pipeline stages portion of the pipeline mini graph.
*/
export default {
components: {
PipelineStage,
},
props: {
stages: {
type: Array,
required: true,
},
updateDropdown: {
type: Boolean,
required: false,
default: false,
},
stagesClass: {
type: [Array, Object, String],
required: false,
default: '',
},
isMergeTrain: {
type: Boolean,
required: false,
default: false,
},
},
methods: {
onPipelineActionRequestComplete() {
this.$emit('pipelineActionRequestComplete');
},
},
};
</script>
<template>
<div data-testid="pipeline-stages" class="gl-display-inline gl-vertical-align-middle">
<div
v-for="stage in stages"
:key="stage.name"
:class="stagesClass"
class="dropdown gl-display-inline-block gl-mr-2 gl-my-2 gl-vertical-align-middle stage-container"
>
<pipeline-stage
:stage="stage"
:update-dropdown="updateDropdown"
:is-merge-train="isMergeTrain"
@pipelineActionRequestComplete="onPipelineActionRequestComplete"
/>
</div>
</div>
</template>

View File

@ -17,6 +17,8 @@ const DEFAULT_TH_CLASSES =
export default {
components: {
GlTableLite,
LinkedPipelinesMiniList: () =>
import('ee_component/vue_shared/components/linked_pipelines_mini_list.vue'),
PipelineMiniGraph,
PipelineOperations,
PipelinesStatusBadge,
@ -167,14 +169,29 @@ export default {
</template>
<template #cell(stages)="{ item }">
<pipeline-mini-graph
:downstream-pipelines="item.triggered"
:pipeline-path="item.path"
:stages="item.details.stages"
:update-dropdown="updateGraphDropdown"
:upstream-pipeline="item.triggered_by"
@pipelineActionRequestComplete="onPipelineActionRequestComplete"
/>
<div class="stage-cell">
<!-- This empty div should be removed, see https://gitlab.com/gitlab-org/gitlab/-/issues/323488 -->
<div></div>
<linked-pipelines-mini-list
v-if="item.triggered_by"
:triggered-by="/* eslint-disable @gitlab/vue-no-new-non-primitive-in-template */ [
item.triggered_by,
] /* eslint-enable @gitlab/vue-no-new-non-primitive-in-template */"
data-testid="mini-graph-upstream"
/>
<pipeline-mini-graph
v-if="item.details && item.details.stages && item.details.stages.length > 0"
:stages="item.details.stages"
:update-dropdown="updateGraphDropdown"
@pipelineActionRequestComplete="onPipelineActionRequestComplete"
/>
<linked-pipelines-mini-list
v-if="item.triggered.length"
:triggered="item.triggered"
:pipeline-path="item.path"
data-testid="mini-graph-downstream"
/>
</div>
</template>
<template #cell(actions)="{ item }">

View File

@ -2,11 +2,11 @@
import { GlLoadingIcon } from '@gitlab/ui';
import createFlash from '~/flash';
import { __ } from '~/locale';
import PipelineMiniGraph from '~/pipelines/components/pipelines_list/pipeline_mini_graph.vue';
import {
getQueryHeaders,
toggleQueryPollingByVisibility,
} from '~/pipelines/components/graph/utils';
import PipelineMiniGraph from '~/pipelines/components/pipelines_list/pipeline_mini_graph.vue';
import { formatStages } from '../utils';
import getLinkedPipelinesQuery from '../graphql/queries/get_linked_pipelines.query.graphql';
import getPipelineStagesQuery from '../graphql/queries/get_pipeline_stages.query.graphql';
@ -21,6 +21,8 @@ export default {
components: {
GlLoadingIcon,
PipelineMiniGraph,
LinkedPipelinesMiniList: () =>
import('ee_component/vue_shared/components/linked_pipelines_mini_list.vue'),
},
inject: {
fullPath: {
@ -90,12 +92,12 @@ export default {
};
},
computed: {
hasDownstream() {
return this.pipeline?.downstream?.nodes.length > 0;
},
downstreamPipelines() {
return this.pipeline?.downstream?.nodes;
},
pipelinePath() {
return this.pipeline?.path ?? '';
},
upstreamPipeline() {
return this.pipeline?.upstream;
},
@ -126,13 +128,23 @@ export default {
<template>
<div class="gl-pt-2">
<gl-loading-icon v-if="$apollo.queries.pipeline.loading" />
<pipeline-mini-graph
v-else
data-testid="commit-box-pipeline-mini-graph"
:downstream-pipelines="downstreamPipelines"
:pipeline-path="pipelinePath"
:stages="formattedStages"
:upstream-pipeline="upstreamPipeline"
/>
<div v-else class="gl-align-items-center gl-display-flex">
<linked-pipelines-mini-list
v-if="upstreamPipeline"
:triggered-by="/* eslint-disable @gitlab/vue-no-new-non-primitive-in-template */ [
upstreamPipeline,
] /* eslint-enable @gitlab/vue-no-new-non-primitive-in-template */"
data-testid="commit-box-mini-graph-upstream"
/>
<pipeline-mini-graph :stages="formattedStages" data-testid="commit-box-mini-graph" />
<linked-pipelines-mini-list
v-if="hasDownstream"
:triggered="downstreamPipelines"
:pipeline-path="pipeline.path"
data-testid="commit-box-mini-graph-downstream"
/>
</div>
</div>
</template>

View File

@ -11,8 +11,8 @@ import {
} from '@gitlab/ui';
import mrWidgetPipelineMixin from 'ee_else_ce/vue_merge_request_widget/mixins/mr_widget_pipeline';
import { s__, n__ } from '~/locale';
import PipelineArtifacts from '~/pipelines/components/pipelines_list/pipelines_artifacts.vue';
import PipelineMiniGraph from '~/pipelines/components/pipelines_list/pipeline_mini_graph.vue';
import PipelineArtifacts from '~/pipelines/components/pipelines_list/pipelines_artifacts.vue';
import CiIcon from '~/vue_shared/components/ci_icon.vue';
import TimeAgoTooltip from '~/vue_shared/components/time_ago_tooltip.vue';
import TooltipOnTruncate from '~/vue_shared/components/tooltip_on_truncate/tooltip_on_truncate.vue';
@ -31,6 +31,8 @@ export default {
PipelineMiniGraph,
TimeAgoTooltip,
TooltipOnTruncate,
LinkedPipelinesMiniList: () =>
import('ee_component/vue_shared/components/linked_pipelines_mini_list.vue'),
},
directives: {
GlTooltip: GlTooltipDirective,
@ -274,15 +276,17 @@ export default {
</div>
</div>
<div>
<span class="gl-align-items-center gl-display-inline-flex">
<pipeline-mini-graph
v-if="pipeline.details.stages"
:downstream-pipelines="triggered"
:is-merge-train="isMergeTrain"
:stages="pipeline.details.stages"
:upstream-pipeline="triggeredBy[0]"
stages-class="mr-widget-pipeline-stages"
/>
<span class="gl-align-items-center gl-display-inline-flex mr-widget-pipeline-graph">
<span class="gl-align-items-center gl-display-inline-flex gl-flex-wrap stage-cell">
<linked-pipelines-mini-list v-if="triggeredBy.length" :triggered-by="triggeredBy" />
<pipeline-mini-graph
v-if="hasStages"
stages-class="mr-widget-pipeline-stages"
:stages="pipeline.details.stages"
:is-merge-train="isMergeTrain"
/>
</span>
<linked-pipelines-mini-list v-if="triggered.length" :triggered="triggered" />
<pipeline-artifacts :pipeline-id="pipeline.id" :artifacts="artifacts" class="gl-ml-3" />
</span>
</div>

View File

@ -400,6 +400,12 @@ $tabs-holder-z-index: 250;
display: block;
}
.mr-widget-pipeline-graph {
.dropdown-menu {
z-index: $zindex-dropdown-menu;
}
}
.normal {
flex: 1;
flex-basis: auto;

View File

@ -33,6 +33,12 @@
height: 22px;
}
}
.mr-widget-pipeline-graph {
.dropdown-menu {
margin-top: 11px;
}
}
}
.branch-info .commit-icon {

View File

@ -132,4 +132,4 @@
= sprite_icon('play', css_class: 'gl-icon')
- elsif job.retryable?
= link_to retry_project_job_path(job.project, job, return_to: request.original_url), method: :post, title: _('Retry'), class: 'gl-button btn btn-default btn-icon' do
= sprite_icon('repeat', css_class: 'gl-icon')
= sprite_icon('retry', css_class: 'gl-icon')

View File

@ -9477,7 +9477,7 @@ Represents an epic on an issue board.
| <a id="boardepicblockedbyepics"></a>`blockedByEpics` | [`EpicConnection`](#epicconnection) | Epics blocking this epic. (see [Connections](#connections)) |
| <a id="boardepicblockingcount"></a>`blockingCount` | [`Int`](#int) | Count of epics that this epic is blocking. |
| <a id="boardepicclosedat"></a>`closedAt` | [`Time`](#time) | Timestamp of when the epic was closed. |
| <a id="boardepiccolor"></a>`color` | [`String!`](#string) | Color of the epic. Available only when feature flag `epic_color_highlight` is enabled. This flag is disabled by default, because the feature is experimental and is subject to change without notice. |
| <a id="boardepiccolor"></a>`color` | [`String`](#string) | Color of the epic. Returns `null` if `epic_color_highlight` feature flag is disabled. |
| <a id="boardepicconfidential"></a>`confidential` | [`Boolean`](#boolean) | Indicates if the epic is confidential. |
| <a id="boardepiccreatedat"></a>`createdAt` | [`Time`](#time) | Timestamp of when the epic was created. |
| <a id="boardepicdescendantcounts"></a>`descendantCounts` | [`EpicDescendantCount`](#epicdescendantcount) | Number of open and closed descendant epics and issues. |
@ -9513,7 +9513,7 @@ Represents an epic on an issue board.
| <a id="boardepicstartdateisfixed"></a>`startDateIsFixed` | [`Boolean`](#boolean) | Indicates if the start date has been manually set. |
| <a id="boardepicstate"></a>`state` | [`EpicState!`](#epicstate) | State of the epic. |
| <a id="boardepicsubscribed"></a>`subscribed` | [`Boolean!`](#boolean) | Indicates the currently logged in user is subscribed to the epic. |
| <a id="boardepictextcolor"></a>`textColor` | [`String!`](#string) | Text color generated for the epic. Available only when feature flag `epic_color_highlight` is enabled. This flag is disabled by default, because the feature is experimental and is subject to change without notice. |
| <a id="boardepictextcolor"></a>`textColor` | [`String`](#string) | Text color generated for the epic. Returns `null` if `epic_color_highlight` feature flag is disabled. |
| <a id="boardepictitle"></a>`title` | [`String`](#string) | Title of the epic. |
| <a id="boardepictitlehtml"></a>`titleHtml` | [`String`](#string) | The GitLab Flavored Markdown rendering of `title`. |
| <a id="boardepicupdatedat"></a>`updatedAt` | [`Time`](#time) | Timestamp of when the epic was updated. |
@ -11063,7 +11063,7 @@ Represents an epic.
| <a id="epicblockedbyepics"></a>`blockedByEpics` | [`EpicConnection`](#epicconnection) | Epics blocking this epic. (see [Connections](#connections)) |
| <a id="epicblockingcount"></a>`blockingCount` | [`Int`](#int) | Count of epics that this epic is blocking. |
| <a id="epicclosedat"></a>`closedAt` | [`Time`](#time) | Timestamp of when the epic was closed. |
| <a id="epiccolor"></a>`color` | [`String!`](#string) | Color of the epic. Available only when feature flag `epic_color_highlight` is enabled. This flag is disabled by default, because the feature is experimental and is subject to change without notice. |
| <a id="epiccolor"></a>`color` | [`String`](#string) | Color of the epic. Returns `null` if `epic_color_highlight` feature flag is disabled. |
| <a id="epicconfidential"></a>`confidential` | [`Boolean`](#boolean) | Indicates if the epic is confidential. |
| <a id="epiccreatedat"></a>`createdAt` | [`Time`](#time) | Timestamp of when the epic was created. |
| <a id="epicdescendantcounts"></a>`descendantCounts` | [`EpicDescendantCount`](#epicdescendantcount) | Number of open and closed descendant epics and issues. |
@ -11099,7 +11099,7 @@ Represents an epic.
| <a id="epicstartdateisfixed"></a>`startDateIsFixed` | [`Boolean`](#boolean) | Indicates if the start date has been manually set. |
| <a id="epicstate"></a>`state` | [`EpicState!`](#epicstate) | State of the epic. |
| <a id="epicsubscribed"></a>`subscribed` | [`Boolean!`](#boolean) | Indicates the currently logged in user is subscribed to the epic. |
| <a id="epictextcolor"></a>`textColor` | [`String!`](#string) | Text color generated for the epic. Available only when feature flag `epic_color_highlight` is enabled. This flag is disabled by default, because the feature is experimental and is subject to change without notice. |
| <a id="epictextcolor"></a>`textColor` | [`String`](#string) | Text color generated for the epic. Returns `null` if `epic_color_highlight` feature flag is disabled. |
| <a id="epictitle"></a>`title` | [`String`](#string) | Title of the epic. |
| <a id="epictitlehtml"></a>`titleHtml` | [`String`](#string) | The GitLab Flavored Markdown rendering of `title`. |
| <a id="epicupdatedat"></a>`updatedAt` | [`Time`](#time) | Timestamp of when the epic was updated. |

View File

@ -20,7 +20,7 @@ over [`git filter-branch`](https://git-scm.com/docs/git-filter-branch) and
WARNING:
Rewriting repository history is a destructive operation. Make sure to back up your repository before
you begin. The best way back up a repository is to
you begin. The best way to back up a repository is to
[export the project](../settings/import_export.md#export-a-project-and-its-data).
## Purge files from repository history

View File

@ -27,7 +27,7 @@ RSpec.describe 'Mini Pipeline Graph in Commit View', :js do
end
it 'displays a mini pipeline graph' do
expect(page).to have_selector('[data-testid="commit-box-pipeline-mini-graph"]')
expect(page).to have_selector('[data-testid="commit-box-mini-graph"]')
first('[data-testid="mini-pipeline-graph-dropdown"]').click

View File

@ -6,7 +6,6 @@ import { extendedWrapper } from 'helpers/vue_test_utils_helper';
import waitForPromises from 'helpers/wait_for_promises';
import createFlash from '~/flash';
import CommitBoxPipelineMiniGraph from '~/projects/commit_box/info/components/commit_box_pipeline_mini_graph.vue';
import PipelineMiniGraph from '~/pipelines/components/pipelines_list/pipeline_mini_graph.vue';
import getLinkedPipelinesQuery from '~/projects/commit_box/info/graphql/queries/get_linked_pipelines.query.graphql';
import getPipelineStagesQuery from '~/projects/commit_box/info/graphql/queries/get_pipeline_stages.query.graphql';
import { mockPipelineStagesQueryResponse, mockStages } from './mock_data';
@ -18,7 +17,9 @@ Vue.use(VueApollo);
describe('Commit box pipeline mini graph', () => {
let wrapper;
const findPipelineMiniGraph = () => wrapper.findComponent(PipelineMiniGraph);
const findMiniGraph = () => wrapper.findByTestId('commit-box-mini-graph');
const findUpstream = () => wrapper.findByTestId('commit-box-mini-graph-upstream');
const findDownstream = () => wrapper.findByTestId('commit-box-mini-graph-downstream');
const stagesHandler = jest.fn().mockResolvedValue(mockPipelineStagesQueryResponse);
@ -50,16 +51,13 @@ describe('Commit box pipeline mini graph', () => {
await createComponent();
});
it('should display the pipeline mini graph', () => {
expect(findPipelineMiniGraph().exists()).toBe(true);
it('should display the mini pipeine graph', () => {
expect(findMiniGraph().exists()).toBe(true);
});
it('should not display linked pipelines', () => {
const downstreamPipelines = findPipelineMiniGraph().props('downstreamPipelines');
const upstreamPipeline = findPipelineMiniGraph().props('upstreamPipeline');
expect(downstreamPipelines).toHaveLength(0);
expect(upstreamPipeline).toEqual(undefined);
expect(findUpstream().exists()).toBe(false);
expect(findDownstream().exists()).toBe(false);
});
});

View File

@ -1,109 +0,0 @@
import { shallowMount } from '@vue/test-utils';
import Vue from 'vue';
import VueApollo from 'vue-apollo';
import createMockApollo from 'helpers/mock_apollo_helper';
import waitForPromises from 'helpers/wait_for_promises';
import PipelineEditorMiniGraph from '~/pipeline_editor/components/header/pipeline_editor_mini_graph.vue';
import PipelineMiniGraph from '~/pipelines/components/pipelines_list/pipeline_mini_graph.vue';
import getLinkedPipelinesQuery from '~/projects/commit_box/info/graphql/queries/get_linked_pipelines.query.graphql';
import { PIPELINE_FAILURE } from '~/pipeline_editor/constants';
import { mockLinkedPipelines, mockProjectFullPath, mockProjectPipeline } from '../../mock_data';
Vue.use(VueApollo);
describe('Pipeline Status', () => {
let wrapper;
let mockApollo;
let mockLinkedPipelinesQuery;
const createComponent = ({ hasStages = true, options } = {}) => {
wrapper = shallowMount(PipelineEditorMiniGraph, {
provide: {
dataMethod: 'graphql',
projectFullPath: mockProjectFullPath,
},
propsData: {
pipeline: mockProjectPipeline({ hasStages }).pipeline,
},
...options,
});
};
const createComponentWithApollo = (hasStages = true) => {
const handlers = [[getLinkedPipelinesQuery, mockLinkedPipelinesQuery]];
mockApollo = createMockApollo(handlers);
createComponent({
hasStages,
options: {
apolloProvider: mockApollo,
},
});
};
const findPipelineMiniGraph = () => wrapper.findComponent(PipelineMiniGraph);
beforeEach(() => {
mockLinkedPipelinesQuery = jest.fn();
});
afterEach(() => {
mockLinkedPipelinesQuery.mockReset();
wrapper.destroy();
});
describe('when there are stages', () => {
beforeEach(() => {
createComponent();
});
it('renders pipeline mini graph', () => {
expect(findPipelineMiniGraph().exists()).toBe(true);
});
});
describe('when there are no stages', () => {
beforeEach(() => {
createComponent({ hasStages: false });
});
it('does not render pipeline mini graph', () => {
expect(findPipelineMiniGraph().exists()).toBe(false);
});
});
describe('when querying upstream and downstream pipelines', () => {
describe('when query succeeds', () => {
beforeEach(() => {
mockLinkedPipelinesQuery.mockResolvedValue(mockLinkedPipelines());
createComponentWithApollo();
});
it('should call the query with the correct variables', () => {
expect(mockLinkedPipelinesQuery).toHaveBeenCalledTimes(1);
expect(mockLinkedPipelinesQuery).toHaveBeenCalledWith({
fullPath: mockProjectFullPath,
iid: mockProjectPipeline().pipeline.iid,
});
});
});
describe('when query fails', () => {
beforeEach(async () => {
mockLinkedPipelinesQuery.mockRejectedValue(new Error());
createComponentWithApollo();
await waitForPromises();
});
it('should emit an error event when query fails', async () => {
expect(wrapper.emitted('showError')).toHaveLength(1);
expect(wrapper.emitted('showError')[0]).toEqual([
{
type: PIPELINE_FAILURE,
reasons: [wrapper.vm.$options.i18n.linkedPipelinesFetchError],
},
]);
});
});
});
});

View File

@ -1,18 +1,18 @@
import { shallowMount } from '@vue/test-utils';
import { pipelines } from 'test_fixtures/pipelines/pipelines.json';
import PipelineMiniGraph from '~/pipelines/components/pipelines_list/pipeline_mini_graph.vue';
import PipelineStage from '~/pipelines/components/pipelines_list/pipeline_stage.vue';
import PipelineStages from '~/pipelines/components/pipelines_list/pipeline_stages.vue';
const mockStages = pipelines[0].details.stages;
describe('Pipeline Stages', () => {
describe('Pipeline Mini Graph', () => {
let wrapper;
const findPipelineStages = () => wrapper.findAll(PipelineStage);
const findPipelineStagesAt = (i) => findPipelineStages().at(i);
const createComponent = (props = {}) => {
wrapper = shallowMount(PipelineStages, {
wrapper = shallowMount(PipelineMiniGraph, {
propsData: {
stages: mockStages,
...props,

View File

@ -1,407 +0,0 @@
export default {
triggered_by: {
id: 129,
active: true,
path: '/gitlab-org/gitlab-foss/-/pipelines/129',
project: {
name: 'GitLabCE',
},
details: {
status: {
icon: 'status_running',
text: 'running',
label: 'running',
group: 'running',
has_details: true,
details_path: '/gitlab-org/gitlab-foss/-/pipelines/129',
favicon:
'/assets/ci_favicons/dev/favicon_status_running-c3ad2fc53ea6079c174e5b6c1351ff349e99ec3af5a5622fb77b0fe53ea279c1.ico',
},
},
flags: {
latest: false,
triggered: false,
stuck: false,
yaml_errors: false,
retryable: true,
cancelable: true,
},
ref: {
name: '7-5-stable',
path: '/gitlab-org/gitlab-foss/commits/7-5-stable',
tag: false,
branch: true,
},
commit: {
id: '23433d4d8b20d7e45c103d0b6048faad38a130ab',
short_id: '23433d4d',
title: 'Version 7.5.0.rc1',
created_at: '2014-11-17T15:44:14.000+01:00',
parent_ids: ['30ac909f30f58d319b42ed1537664483894b18cd'],
message: 'Version 7.5.0.rc1\n',
author_name: 'Jacob Vosmaer',
author_email: 'contact@jacobvosmaer.nl',
authored_date: '2014-11-17T15:44:14.000+01:00',
committer_name: 'Jacob Vosmaer',
committer_email: 'contact@jacobvosmaer.nl',
committed_date: '2014-11-17T15:44:14.000+01:00',
author_gravatar_url:
'http://www.gravatar.com/avatar/e66d11c0eedf8c07b3b18fca46599807?s=80&d=identicon',
commit_url:
'http://localhost:3000/gitlab-org/gitlab-foss/commit/23433d4d8b20d7e45c103d0b6048faad38a130ab',
commit_path: '/gitlab-org/gitlab-foss/commit/23433d4d8b20d7e45c103d0b6048faad38a130ab',
},
retry_path: '/gitlab-org/gitlab-foss/-/pipelines/129/retry',
cancel_path: '/gitlab-org/gitlab-foss/-/pipelines/129/cancel',
created_at: '2017-05-24T14:46:20.090Z',
updated_at: '2017-05-24T14:46:29.906Z',
},
triggered: [
{
id: 132,
active: true,
path: '/gitlab-org/gitlab-foss/-/pipelines/132',
project: {
name: 'GitLabCE',
},
details: {
status: {
icon: 'status_running',
text: 'running',
label: 'running',
group: 'running',
has_details: true,
details_path: '/gitlab-org/gitlab-foss/-/pipelines/132',
favicon:
'/assets/ci_favicons/dev/favicon_status_running-c3ad2fc53ea6079c174e5b6c1351ff349e99ec3af5a5622fb77b0fe53ea279c1.ico',
},
},
flags: {
latest: false,
triggered: false,
stuck: false,
yaml_errors: false,
retryable: true,
cancelable: true,
},
ref: {
name: 'crowd',
path: '/gitlab-org/gitlab-foss/commits/crowd',
tag: false,
branch: true,
},
commit: {
id: 'b9d58c4cecd06be74c3cc32ccfb522b31544ab2e',
short_id: 'b9d58c4c',
title: 'getting user keys publically through http without any authentication, the github…',
created_at: '2013-10-03T12:50:33.000+05:30',
parent_ids: ['e219cf7246c6a0495e4507deaffeba11e79f13b8'],
message:
'getting user keys publically through http without any authentication, the github way. E.g: http://github.com/devaroop.keys\n\nchangelog updated to include ssh key retrieval feature update\n',
author_name: 'devaroop',
author_email: 'devaroop123@yahoo.co.in',
authored_date: '2013-10-02T20:39:29.000+05:30',
committer_name: 'devaroop',
committer_email: 'devaroop123@yahoo.co.in',
committed_date: '2013-10-03T12:50:33.000+05:30',
author_gravatar_url:
'http://www.gravatar.com/avatar/35df4b155ec66a3127d53459941cf8a2?s=80&d=identicon',
commit_url:
'http://localhost:3000/gitlab-org/gitlab-foss/commit/b9d58c4cecd06be74c3cc32ccfb522b31544ab2e',
commit_path: '/gitlab-org/gitlab-foss/commit/b9d58c4cecd06be74c3cc32ccfb522b31544ab2e',
},
retry_path: '/gitlab-org/gitlab-foss/-/pipelines/132/retry',
cancel_path: '/gitlab-org/gitlab-foss/-/pipelines/132/cancel',
created_at: '2017-05-24T14:46:24.644Z',
updated_at: '2017-05-24T14:48:55.226Z',
},
{
id: 133,
active: true,
path: '/gitlab-org/gitlab-foss/-/pipelines/133',
project: {
name: 'GitLabCE',
},
details: {
status: {
icon: 'status_running',
text: 'running',
label: 'running',
group: 'running',
has_details: true,
details_path: '/gitlab-org/gitlab-foss/-/pipelines/133',
favicon:
'/assets/ci_favicons/dev/favicon_status_running-c3ad2fc53ea6079c174e5b6c1351ff349e99ec3af5a5622fb77b0fe53ea279c1.ico',
},
},
flags: {
latest: false,
triggered: false,
stuck: false,
yaml_errors: false,
retryable: true,
cancelable: true,
},
ref: {
name: 'crowd',
path: '/gitlab-org/gitlab-foss/commits/crowd',
tag: false,
branch: true,
},
commit: {
id: 'b6bd4856a33df3d144be66c4ed1f1396009bb08b',
short_id: 'b6bd4856',
title: 'getting user keys publically through http without any authentication, the github…',
created_at: '2013-10-02T20:39:29.000+05:30',
parent_ids: ['e219cf7246c6a0495e4507deaffeba11e79f13b8'],
message:
'getting user keys publically through http without any authentication, the github way. E.g: http://github.com/devaroop.keys\n',
author_name: 'devaroop',
author_email: 'devaroop123@yahoo.co.in',
authored_date: '2013-10-02T20:39:29.000+05:30',
committer_name: 'devaroop',
committer_email: 'devaroop123@yahoo.co.in',
committed_date: '2013-10-02T20:39:29.000+05:30',
author_gravatar_url:
'http://www.gravatar.com/avatar/35df4b155ec66a3127d53459941cf8a2?s=80&d=identicon',
commit_url:
'http://localhost:3000/gitlab-org/gitlab-foss/commit/b6bd4856a33df3d144be66c4ed1f1396009bb08b',
commit_path: '/gitlab-org/gitlab-foss/commit/b6bd4856a33df3d144be66c4ed1f1396009bb08b',
},
retry_path: '/gitlab-org/gitlab-foss/-/pipelines/133/retry',
cancel_path: '/gitlab-org/gitlab-foss/-/pipelines/133/cancel',
created_at: '2017-05-24T14:46:24.648Z',
updated_at: '2017-05-24T14:48:59.673Z',
},
{
id: 130,
active: true,
path: '/gitlab-org/gitlab-foss/-/pipelines/130',
project: {
name: 'GitLabCE',
},
details: {
status: {
icon: 'status_running',
text: 'running',
label: 'running',
group: 'running',
has_details: true,
details_path: '/gitlab-org/gitlab-foss/-/pipelines/130',
favicon:
'/assets/ci_favicons/dev/favicon_status_running-c3ad2fc53ea6079c174e5b6c1351ff349e99ec3af5a5622fb77b0fe53ea279c1.ico',
},
},
flags: {
latest: false,
triggered: false,
stuck: false,
yaml_errors: false,
retryable: true,
cancelable: true,
},
ref: {
name: 'crowd',
path: '/gitlab-org/gitlab-foss/commits/crowd',
tag: false,
branch: true,
},
commit: {
id: '6d7ced4a2311eeff037c5575cca1868a6d3f586f',
short_id: '6d7ced4a',
title: 'Whitespace fixes to patch',
created_at: '2013-10-08T13:53:22.000-05:00',
parent_ids: ['1875141a963a4238bda29011d8f7105839485253'],
message: 'Whitespace fixes to patch\n',
author_name: 'Dale Hamel',
author_email: 'dale.hamel@srvthe.net',
authored_date: '2013-10-08T13:53:22.000-05:00',
committer_name: 'Dale Hamel',
committer_email: 'dale.hamel@invenia.ca',
committed_date: '2013-10-08T13:53:22.000-05:00',
author_gravatar_url:
'http://www.gravatar.com/avatar/cd08930e69fa5ad1a669206e7bafe476?s=80&d=identicon',
commit_url:
'http://localhost:3000/gitlab-org/gitlab-foss/commit/6d7ced4a2311eeff037c5575cca1868a6d3f586f',
commit_path: '/gitlab-org/gitlab-foss/commit/6d7ced4a2311eeff037c5575cca1868a6d3f586f',
},
retry_path: '/gitlab-org/gitlab-foss/-/pipelines/130/retry',
cancel_path: '/gitlab-org/gitlab-foss/-/pipelines/130/cancel',
created_at: '2017-05-24T14:46:24.630Z',
updated_at: '2017-05-24T14:49:45.091Z',
},
{
id: 131,
active: true,
path: '/gitlab-org/gitlab-foss/-/pipelines/132',
project: {
name: 'GitLabCE',
},
details: {
status: {
icon: 'status_running',
text: 'running',
label: 'running',
group: 'running',
has_details: true,
details_path: '/gitlab-org/gitlab-foss/-/pipelines/132',
favicon:
'/assets/ci_favicons/dev/favicon_status_running-c3ad2fc53ea6079c174e5b6c1351ff349e99ec3af5a5622fb77b0fe53ea279c1.ico',
},
},
flags: {
latest: false,
triggered: false,
stuck: false,
yaml_errors: false,
retryable: true,
cancelable: true,
},
ref: {
name: 'crowd',
path: '/gitlab-org/gitlab-foss/commits/crowd',
tag: false,
branch: true,
},
commit: {
id: 'b9d58c4cecd06be74c3cc32ccfb522b31544ab2e',
short_id: 'b9d58c4c',
title: 'getting user keys publically through http without any authentication, the github…',
created_at: '2013-10-03T12:50:33.000+05:30',
parent_ids: ['e219cf7246c6a0495e4507deaffeba11e79f13b8'],
message:
'getting user keys publically through http without any authentication, the github way. E.g: http://github.com/devaroop.keys\n\nchangelog updated to include ssh key retrieval feature update\n',
author_name: 'devaroop',
author_email: 'devaroop123@yahoo.co.in',
authored_date: '2013-10-02T20:39:29.000+05:30',
committer_name: 'devaroop',
committer_email: 'devaroop123@yahoo.co.in',
committed_date: '2013-10-03T12:50:33.000+05:30',
author_gravatar_url:
'http://www.gravatar.com/avatar/35df4b155ec66a3127d53459941cf8a2?s=80&d=identicon',
commit_url:
'http://localhost:3000/gitlab-org/gitlab-foss/commit/b9d58c4cecd06be74c3cc32ccfb522b31544ab2e',
commit_path: '/gitlab-org/gitlab-foss/commit/b9d58c4cecd06be74c3cc32ccfb522b31544ab2e',
},
retry_path: '/gitlab-org/gitlab-foss/-/pipelines/132/retry',
cancel_path: '/gitlab-org/gitlab-foss/-/pipelines/132/cancel',
created_at: '2017-05-24T14:46:24.644Z',
updated_at: '2017-05-24T14:48:55.226Z',
},
{
id: 134,
active: true,
path: '/gitlab-org/gitlab-foss/-/pipelines/133',
project: {
name: 'GitLabCE',
},
details: {
status: {
icon: 'status_running',
text: 'running',
label: 'running',
group: 'running',
has_details: true,
details_path: '/gitlab-org/gitlab-foss/-/pipelines/133',
favicon:
'/assets/ci_favicons/dev/favicon_status_running-c3ad2fc53ea6079c174e5b6c1351ff349e99ec3af5a5622fb77b0fe53ea279c1.ico',
},
},
flags: {
latest: false,
triggered: false,
stuck: false,
yaml_errors: false,
retryable: true,
cancelable: true,
},
ref: {
name: 'crowd',
path: '/gitlab-org/gitlab-foss/commits/crowd',
tag: false,
branch: true,
},
commit: {
id: 'b6bd4856a33df3d144be66c4ed1f1396009bb08b',
short_id: 'b6bd4856',
title: 'getting user keys publically through http without any authentication, the github…',
created_at: '2013-10-02T20:39:29.000+05:30',
parent_ids: ['e219cf7246c6a0495e4507deaffeba11e79f13b8'],
message:
'getting user keys publically through http without any authentication, the github way. E.g: http://github.com/devaroop.keys\n',
author_name: 'devaroop',
author_email: 'devaroop123@yahoo.co.in',
authored_date: '2013-10-02T20:39:29.000+05:30',
committer_name: 'devaroop',
committer_email: 'devaroop123@yahoo.co.in',
committed_date: '2013-10-02T20:39:29.000+05:30',
author_gravatar_url:
'http://www.gravatar.com/avatar/35df4b155ec66a3127d53459941cf8a2?s=80&d=identicon',
commit_url:
'http://localhost:3000/gitlab-org/gitlab-foss/commit/b6bd4856a33df3d144be66c4ed1f1396009bb08b',
commit_path: '/gitlab-org/gitlab-foss/commit/b6bd4856a33df3d144be66c4ed1f1396009bb08b',
},
retry_path: '/gitlab-org/gitlab-foss/-/pipelines/133/retry',
cancel_path: '/gitlab-org/gitlab-foss/-/pipelines/133/cancel',
created_at: '2017-05-24T14:46:24.648Z',
updated_at: '2017-05-24T14:48:59.673Z',
},
{
id: 135,
active: true,
path: '/gitlab-org/gitlab-foss/-/pipelines/130',
project: {
name: 'GitLabCE',
},
details: {
status: {
icon: 'status_running',
text: 'running',
label: 'running',
group: 'running',
has_details: true,
details_path: '/gitlab-org/gitlab-foss/-/pipelines/130',
favicon:
'/assets/ci_favicons/dev/favicon_status_running-c3ad2fc53ea6079c174e5b6c1351ff349e99ec3af5a5622fb77b0fe53ea279c1.ico',
},
},
flags: {
latest: false,
triggered: false,
stuck: false,
yaml_errors: false,
retryable: true,
cancelable: true,
},
ref: {
name: 'crowd',
path: '/gitlab-org/gitlab-foss/commits/crowd',
tag: false,
branch: true,
},
commit: {
id: '6d7ced4a2311eeff037c5575cca1868a6d3f586f',
short_id: '6d7ced4a',
title: 'Whitespace fixes to patch',
created_at: '2013-10-08T13:53:22.000-05:00',
parent_ids: ['1875141a963a4238bda29011d8f7105839485253'],
message: 'Whitespace fixes to patch\n',
author_name: 'Dale Hamel',
author_email: 'dale.hamel@srvthe.net',
authored_date: '2013-10-08T13:53:22.000-05:00',
committer_name: 'Dale Hamel',
committer_email: 'dale.hamel@invenia.ca',
committed_date: '2013-10-08T13:53:22.000-05:00',
author_gravatar_url:
'http://www.gravatar.com/avatar/cd08930e69fa5ad1a669206e7bafe476?s=80&d=identicon',
commit_url:
'http://localhost:3000/gitlab-org/gitlab-foss/commit/6d7ced4a2311eeff037c5575cca1868a6d3f586f',
commit_path: '/gitlab-org/gitlab-foss/commit/6d7ced4a2311eeff037c5575cca1868a6d3f586f',
},
retry_path: '/gitlab-org/gitlab-foss/-/pipelines/130/retry',
cancel_path: '/gitlab-org/gitlab-foss/-/pipelines/130/cancel',
created_at: '2017-05-24T14:46:24.630Z',
updated_at: '2017-05-24T14:49:45.091Z',
},
],
};

View File

@ -1,149 +0,0 @@
import { mount } from '@vue/test-utils';
import { pipelines } from 'test_fixtures/pipelines/pipelines.json';
import PipelineMiniGraph from '~/pipelines/components/pipelines_list/pipeline_mini_graph.vue';
import PipelineStages from '~/pipelines/components/pipelines_list/pipeline_stages.vue';
import mockLinkedPipelines from './linked_pipelines_mock_data';
const mockStages = pipelines[0].details.stages;
describe('Pipeline Mini Graph', () => {
let wrapper;
const findPipelineMiniGraph = () => wrapper.findComponent(PipelineMiniGraph);
const findPipelineStages = () => wrapper.findComponent(PipelineStages);
const findLinkedPipelineUpstream = () =>
wrapper.findComponent('[data-testid="pipeline-mini-graph-upstream"]');
const findLinkedPipelineDownstream = () =>
wrapper.findComponent('[data-testid="pipeline-mini-graph-downstream"]');
const findDownstreamArrowIcon = () => wrapper.find('[data-testid="downstream-arrow-icon"]');
const findUpstreamArrowIcon = () => wrapper.find('[data-testid="upstream-arrow-icon"]');
const createComponent = (props = {}) => {
wrapper = mount(PipelineMiniGraph, {
propsData: {
stages: mockStages,
...props,
},
});
};
describe('rendered state without upstream or downstream pipelines', () => {
beforeEach(() => {
createComponent();
});
afterEach(() => {
wrapper.destroy();
wrapper = null;
});
it('should render the pipeline stages', () => {
expect(findPipelineStages().exists()).toBe(true);
});
it('should have the correct props', () => {
expect(findPipelineMiniGraph().props()).toMatchObject({
downstreamPipelines: [],
isMergeTrain: false,
pipelinePath: '',
stages: expect.any(Array),
stagesClass: '',
updateDropdown: false,
upstreamPipeline: undefined,
});
});
it('should have no linked pipelines', () => {
expect(findLinkedPipelineDownstream().exists()).toBe(false);
expect(findLinkedPipelineUpstream().exists()).toBe(false);
});
it('should not render arrow icons', () => {
expect(findUpstreamArrowIcon().exists()).toBe(false);
expect(findDownstreamArrowIcon().exists()).toBe(false);
});
it('triggers events in "action request complete"', () => {
createComponent();
findPipelineMiniGraph(0).vm.$emit('pipelineActionRequestComplete');
findPipelineMiniGraph(1).vm.$emit('pipelineActionRequestComplete');
expect(wrapper.emitted('pipelineActionRequestComplete')).toHaveLength(2);
});
});
describe('rendered state with upstream pipeline', () => {
beforeEach(() => {
createComponent({
upstreamPipeline: mockLinkedPipelines.triggered_by,
});
});
afterEach(() => {
wrapper.destroy();
wrapper = null;
});
it('should have the correct props', () => {
expect(findPipelineMiniGraph().props()).toMatchObject({
downstreamPipelines: [],
isMergeTrain: false,
pipelinePath: '',
stages: expect.any(Array),
stagesClass: '',
updateDropdown: false,
upstreamPipeline: expect.any(Object),
});
});
it('should render the upstream linked pipelines mini list only', () => {
expect(findLinkedPipelineUpstream().exists()).toBe(true);
expect(findLinkedPipelineDownstream().exists()).toBe(false);
});
it('should render an upstream arrow icon only', () => {
expect(findDownstreamArrowIcon().exists()).toBe(false);
expect(findUpstreamArrowIcon().exists()).toBe(true);
expect(findUpstreamArrowIcon().props('name')).toBe('long-arrow');
});
});
describe('rendered state with downstream pipelines', () => {
beforeEach(() => {
createComponent({
downstreamPipelines: mockLinkedPipelines.triggered,
pipelinePath: 'my/pipeline/path',
});
});
it('should have the correct props', () => {
expect(findPipelineMiniGraph().props()).toMatchObject({
downstreamPipelines: expect.any(Array),
isMergeTrain: false,
pipelinePath: 'my/pipeline/path',
stages: expect.any(Array),
stagesClass: '',
updateDropdown: false,
upstreamPipeline: undefined,
});
});
afterEach(() => {
wrapper.destroy();
wrapper = null;
});
it('should render the downstream linked pipelines mini list only', () => {
expect(findLinkedPipelineDownstream().exists()).toBe(true);
expect(findLinkedPipelineUpstream().exists()).toBe(false);
});
it('should render a downstream arrow icon only', () => {
expect(findUpstreamArrowIcon().exists()).toBe(false);
expect(findDownstreamArrowIcon().exists()).toBe(true);
expect(findDownstreamArrowIcon().props('name')).toBe('long-arrow');
});
});
});

View File

@ -113,28 +113,40 @@ describe('Pipelines Table', () => {
});
describe('stages cell', () => {
it('should render pipeline mini graph', () => {
it('should render a pipeline mini graph', () => {
expect(findPipelineMiniGraph().exists()).toBe(true);
});
it('should render the right number of stages', () => {
const stagesLength = pipeline.details.stages.length;
expect(findPipelineMiniGraph().props('stages').length).toBe(stagesLength);
expect(
findPipelineMiniGraph().findAll('[data-testid="mini-pipeline-graph-dropdown"]'),
).toHaveLength(stagesLength);
});
describe('when pipeline does not have stages', () => {
beforeEach(() => {
pipeline = createMockPipeline();
pipeline.details.stages = [];
pipeline.details.stages = null;
createComponent({ pipelines: [pipeline] });
});
it('stages are not rendered', () => {
expect(findPipelineMiniGraph().props('stages')).toHaveLength(0);
expect(findPipelineMiniGraph().exists()).toBe(false);
});
});
it('should not update dropdown', () => {
expect(findPipelineMiniGraph().props('updateDropdown')).toBe(false);
});
it('when update graph dropdown is set, should update graph dropdown', () => {
createComponent({ pipelines: [pipeline], updateGraphDropdown: true });
expect(findPipelineMiniGraph().props('updateDropdown')).toBe(true);
});
it('when action request is complete, should refresh table', () => {
findPipelineMiniGraph().vm.$emit('pipelineActionRequestComplete');

View File

@ -4,8 +4,9 @@ import axios from 'axios';
import MockAdapter from 'axios-mock-adapter';
import { trimText } from 'helpers/text_helper';
import { extendedWrapper } from 'helpers/vue_test_utils_helper';
import MRWidgetPipelineComponent from '~/vue_merge_request_widget/components/mr_widget_pipeline.vue';
import PipelineMiniGraph from '~/pipelines/components/pipelines_list/pipeline_mini_graph.vue';
import PipelineStage from '~/pipelines/components/pipelines_list/pipeline_stage.vue';
import PipelineComponent from '~/vue_merge_request_widget/components/mr_widget_pipeline.vue';
import { SUCCESS } from '~/vue_merge_request_widget/constants';
import mockData from '../mock_data';
@ -29,13 +30,14 @@ describe('MRWidgetPipeline', () => {
const findPipelineInfoContainer = () => wrapper.findByTestId('pipeline-info-container');
const findCommitLink = () => wrapper.findByTestId('commit-link');
const findPipelineFinishedAt = () => wrapper.findByTestId('finished-at');
const findPipelineMiniGraph = () => wrapper.findComponent(PipelineMiniGraph);
const findAllPipelineStages = () => wrapper.findAllComponents(PipelineStage);
const findPipelineCoverage = () => wrapper.findByTestId('pipeline-coverage');
const findPipelineCoverageDelta = () => wrapper.findByTestId('pipeline-coverage-delta');
const findPipelineCoverageTooltipText = () =>
wrapper.findByTestId('pipeline-coverage-tooltip').text();
const findPipelineCoverageDeltaTooltipText = () =>
wrapper.findByTestId('pipeline-coverage-delta-tooltip').text();
const findPipelineMiniGraph = () => wrapper.findComponent(PipelineMiniGraph);
const findMonitoringPipelineMessage = () => wrapper.findByTestId('monitoring-pipeline-message');
const findLoadingIcon = () => wrapper.findComponent(GlLoadingIcon);
@ -43,7 +45,7 @@ describe('MRWidgetPipeline', () => {
const createWrapper = (props = {}, mountFn = shallowMount) => {
wrapper = extendedWrapper(
mountFn(MRWidgetPipelineComponent, {
mountFn(PipelineComponent, {
propsData: {
...defaultProps,
...props,
@ -104,10 +106,8 @@ describe('MRWidgetPipeline', () => {
});
it('should render pipeline graph', () => {
const stagesCount = mockData.pipeline.details.stages.length;
expect(findPipelineMiniGraph().exists()).toBe(true);
expect(findPipelineMiniGraph().props('stages')).toHaveLength(stagesCount);
expect(findAllPipelineStages()).toHaveLength(mockData.pipeline.details.stages.length);
});
describe('should render pipeline coverage information', () => {
@ -176,11 +176,15 @@ describe('MRWidgetPipeline', () => {
expect(findPipelineInfoContainer().text()).toMatch(mockData.pipeline.details.status.label);
});
it('should render pipeline graph', () => {
it('should render pipeline graph with correct styles', () => {
const stagesCount = mockData.pipeline.details.stages.length;
expect(findPipelineMiniGraph().exists()).toBe(true);
expect(findPipelineMiniGraph().props('stages')).toHaveLength(stagesCount);
expect(findPipelineMiniGraph().findAll('.mr-widget-pipeline-stages')).toHaveLength(
stagesCount,
);
expect(findAllPipelineStages()).toHaveLength(stagesCount);
});
it('should render coverage information', () => {