diff options
Diffstat (limited to 'spec/tooling/danger/project_helper_spec.rb')
-rw-r--r-- | spec/tooling/danger/project_helper_spec.rb | 162 |
1 files changed, 81 insertions, 81 deletions
diff --git a/spec/tooling/danger/project_helper_spec.rb b/spec/tooling/danger/project_helper_spec.rb index 48050649f54..898c0ffa10c 100644 --- a/spec/tooling/danger/project_helper_spec.rb +++ b/spec/tooling/danger/project_helper_spec.rb @@ -39,7 +39,7 @@ RSpec.describe Tooling::Danger::ProjectHelper do 'doc/api/openapi/openapi.yaml' | [:docs, :backend] 'doc/api/openapi/any_other_file.yaml' | [:docs, :backend] - 'usage_data.rb' | [:database, :backend, :product_intelligence] + 'usage_data.rb' | [:database, :backend, :analytics_instrumentation] 'doc/foo.md' | [:docs] 'CONTRIBUTING.md' | [:docs] 'LICENSE' | [:docs] @@ -178,75 +178,75 @@ RSpec.describe Tooling::Danger::ProjectHelper do 'foo/bar.txt' | [:none] 'foo/bar.md' | [:none] - 'ee/config/metrics/counts_7d/20210216174919_g_analytics_issues_weekly.yml' | [:product_intelligence] - 'lib/gitlab/usage_data_counters/aggregated_metrics/common.yml' | [:product_intelligence] - 'lib/gitlab/usage_data_counters/hll_redis_counter.rb' | [:backend, :product_intelligence] - 'lib/gitlab/tracking.rb' | [:backend, :product_intelligence] - 'lib/gitlab/usage/service_ping_report.rb' | [:backend, :product_intelligence] - 'lib/gitlab/usage/metrics/key_path_processor.rb' | [:backend, :product_intelligence] - 'spec/lib/gitlab/tracking_spec.rb' | [:backend, :product_intelligence] - 'app/helpers/tracking_helper.rb' | [:backend, :product_intelligence] - 'spec/helpers/tracking_helper_spec.rb' | [:backend, :product_intelligence] - 'lib/generators/rails/usage_metric_definition_generator.rb' | [:backend, :product_intelligence] - 'spec/lib/generators/usage_metric_definition_generator_spec.rb' | [:backend, :product_intelligence] - 'config/metrics/schema.json' | [:product_intelligence] - 'app/assets/javascripts/tracking/foo.js' | [:frontend, :product_intelligence] - 'spec/frontend/tracking/foo.js' | [:frontend, :product_intelligence] - 'spec/frontend/tracking_spec.js' | [:frontend, :product_intelligence] + 'ee/config/metrics/counts_7d/20210216174919_g_analytics_issues_weekly.yml' | [:analytics_instrumentation] + 'lib/gitlab/usage_data_counters/aggregated_metrics/common.yml' | [:analytics_instrumentation] + 'lib/gitlab/usage_data_counters/hll_redis_counter.rb' | [:backend, :analytics_instrumentation] + 'lib/gitlab/tracking.rb' | [:backend, :analytics_instrumentation] + 'lib/gitlab/usage/service_ping_report.rb' | [:backend, :analytics_instrumentation] + 'lib/gitlab/usage/metrics/key_path_processor.rb' | [:backend, :analytics_instrumentation] + 'spec/lib/gitlab/tracking_spec.rb' | [:backend, :analytics_instrumentation] + 'app/helpers/tracking_helper.rb' | [:backend, :analytics_instrumentation] + 'spec/helpers/tracking_helper_spec.rb' | [:backend, :analytics_instrumentation] + 'lib/generators/rails/usage_metric_definition_generator.rb' | [:backend, :analytics_instrumentation] + 'spec/lib/generators/usage_metric_definition_generator_spec.rb' | [:backend, :analytics_instrumentation] + 'config/metrics/schema.json' | [:analytics_instrumentation] + 'app/assets/javascripts/tracking/foo.js' | [:frontend, :analytics_instrumentation] + 'spec/frontend/tracking/foo.js' | [:frontend, :analytics_instrumentation] + 'spec/frontend/tracking_spec.js' | [:frontend, :analytics_instrumentation] 'lib/gitlab/usage_database/foo.rb' | [:backend] - 'config/metrics/counts_7d/test_metric.yml' | [:product_intelligence] - 'config/events/snowplow_event.yml' | [:product_intelligence] - 'config/metrics/schema.json' | [:product_intelligence] - 'doc/api/usage_data.md' | [:product_intelligence] - 'spec/lib/gitlab/usage_data_spec.rb' | [:product_intelligence] - 'spec/lib/gitlab/usage/service_ping_report.rb' | [:backend, :product_intelligence] - 'spec/lib/gitlab/usage/metrics/key_path_processor.rb' | [:backend, :product_intelligence] - - 'app/models/integration.rb' | [:integrations_be, :backend] - 'ee/app/models/integrations/github.rb' | [:integrations_be, :backend] - 'ee/app/models/ee/integrations/jira.rb' | [:integrations_be, :backend] - 'app/models/integrations/chat_message/pipeline_message.rb' | [:integrations_be, :backend] - 'app/models/jira_connect_subscription.rb' | [:integrations_be, :backend] - 'app/models/hooks/service_hook.rb' | [:integrations_be, :backend] - 'ee/app/models/ee/hooks/system_hook.rb' | [:integrations_be, :backend] - 'app/services/concerns/integrations/project_test_data.rb' | [:integrations_be, :backend] - 'ee/app/services/ee/integrations/test/project_service.rb' | [:integrations_be, :backend] - 'app/controllers/concerns/integrations/actions.rb' | [:integrations_be, :backend] - 'ee/app/controllers/concerns/ee/integrations/params.rb' | [:integrations_be, :backend] - 'ee/app/controllers/projects/integrations/jira/issues_controller.rb' | [:integrations_be, :backend] - 'app/controllers/projects/hooks_controller.rb' | [:integrations_be, :backend] - 'app/controllers/admin/hook_logs_controller.rb' | [:integrations_be, :backend] - 'app/controllers/groups/settings/integrations_controller.rb' | [:integrations_be, :backend] - 'app/controllers/jira_connect/branches_controller.rb' | [:integrations_be, :backend] - 'app/controllers/oauth/jira/authorizations_controller.rb' | [:integrations_be, :backend] - 'ee/app/finders/projects/integrations/jira/by_ids_finder.rb' | [:integrations_be, :database, :backend] - 'app/workers/jira_connect/sync_merge_request_worker.rb' | [:integrations_be, :backend] - 'app/workers/propagate_integration_inherit_worker.rb' | [:integrations_be, :backend] - 'app/workers/web_hooks/log_execution_worker.rb' | [:integrations_be, :backend] - 'app/workers/web_hook_worker.rb' | [:integrations_be, :backend] - 'app/workers/project_service_worker.rb' | [:integrations_be, :backend] - 'lib/atlassian/jira_connect/serializers/commit_entity.rb' | [:integrations_be, :backend] - 'lib/api/entities/project_integration.rb' | [:integrations_be, :backend] - 'lib/gitlab/hook_data/note_builder.rb' | [:integrations_be, :backend] - 'lib/gitlab/data_builder/note.rb' | [:integrations_be, :backend] - 'lib/gitlab/web_hooks/recursion_detection.rb' | [:integrations_be, :backend] - 'ee/lib/ee/gitlab/integrations/sti_type.rb' | [:integrations_be, :backend] - 'ee/lib/ee/api/helpers/integrations_helpers.rb' | [:integrations_be, :backend] - 'ee/app/serializers/integrations/jira_serializers/issue_entity.rb' | [:integrations_be, :backend] - 'app/serializers/jira_connect/app_data_serializer.rb' | [:integrations_be, :backend] - 'lib/api/github/entities.rb' | [:integrations_be, :backend] - 'lib/api/v3/github.rb' | [:integrations_be, :backend] + 'config/metrics/counts_7d/test_metric.yml' | [:analytics_instrumentation] + 'config/events/snowplow_event.yml' | [:analytics_instrumentation] + 'config/metrics/schema.json' | [:analytics_instrumentation] + 'doc/api/usage_data.md' | [:analytics_instrumentation] + 'spec/lib/gitlab/usage_data_spec.rb' | [:analytics_instrumentation] + 'spec/lib/gitlab/usage/service_ping_report.rb' | [:backend, :analytics_instrumentation] + 'spec/lib/gitlab/usage/metrics/key_path_processor.rb' | [:backend, :analytics_instrumentation] + + 'app/models/integration.rb' | [:import_integrate_be, :backend] + 'ee/app/models/integrations/github.rb' | [:import_integrate_be, :backend] + 'ee/app/models/ee/integrations/jira.rb' | [:import_integrate_be, :backend] + 'app/models/integrations/chat_message/pipeline_message.rb' | [:import_integrate_be, :backend] + 'app/models/jira_connect_subscription.rb' | [:import_integrate_be, :backend] + 'app/models/hooks/service_hook.rb' | [:import_integrate_be, :backend] + 'ee/app/models/ee/hooks/system_hook.rb' | [:import_integrate_be, :backend] + 'app/services/concerns/integrations/project_test_data.rb' | [:import_integrate_be, :backend] + 'ee/app/services/ee/integrations/test/project_service.rb' | [:import_integrate_be, :backend] + 'app/controllers/concerns/integrations/actions.rb' | [:import_integrate_be, :backend] + 'ee/app/controllers/concerns/ee/integrations/params.rb' | [:import_integrate_be, :backend] + 'ee/app/controllers/projects/integrations/jira/issues_controller.rb' | [:import_integrate_be, :backend] + 'app/controllers/projects/hooks_controller.rb' | [:import_integrate_be, :backend] + 'app/controllers/admin/hook_logs_controller.rb' | [:import_integrate_be, :backend] + 'app/controllers/groups/settings/integrations_controller.rb' | [:import_integrate_be, :backend] + 'app/controllers/jira_connect/branches_controller.rb' | [:import_integrate_be, :backend] + 'app/controllers/oauth/jira/authorizations_controller.rb' | [:import_integrate_be, :backend] + 'ee/app/finders/projects/integrations/jira/by_ids_finder.rb' | [:import_integrate_be, :database, :backend] + 'app/workers/jira_connect/sync_merge_request_worker.rb' | [:import_integrate_be, :backend] + 'app/workers/propagate_integration_inherit_worker.rb' | [:import_integrate_be, :backend] + 'app/workers/web_hooks/log_execution_worker.rb' | [:import_integrate_be, :backend] + 'app/workers/web_hook_worker.rb' | [:import_integrate_be, :backend] + 'app/workers/project_service_worker.rb' | [:import_integrate_be, :backend] + 'lib/atlassian/jira_connect/serializers/commit_entity.rb' | [:import_integrate_be, :backend] + 'lib/api/entities/project_integration.rb' | [:import_integrate_be, :backend] + 'lib/gitlab/hook_data/note_builder.rb' | [:import_integrate_be, :backend] + 'lib/gitlab/data_builder/note.rb' | [:import_integrate_be, :backend] + 'lib/gitlab/web_hooks/recursion_detection.rb' | [:import_integrate_be, :backend] + 'ee/lib/ee/gitlab/integrations/sti_type.rb' | [:import_integrate_be, :backend] + 'ee/lib/ee/api/helpers/integrations_helpers.rb' | [:import_integrate_be, :backend] + 'ee/app/serializers/integrations/jira_serializers/issue_entity.rb' | [:import_integrate_be, :backend] + 'app/serializers/jira_connect/app_data_serializer.rb' | [:import_integrate_be, :backend] + 'lib/api/github/entities.rb' | [:import_integrate_be, :backend] + 'lib/api/v3/github.rb' | [:import_integrate_be, :backend] 'app/controllers/clusters/integrations_controller.rb' | [:backend] 'app/services/clusters/integrations/prometheus_health_check_service.rb' | [:backend] 'app/graphql/types/alert_management/integration_type.rb' | [:backend] - 'app/views/jira_connect/branches/new.html.haml' | [:integrations_fe, :frontend] - 'app/views/layouts/jira_connect.html.haml' | [:integrations_fe, :frontend] - 'app/assets/javascripts/jira_connect/branches/pages/index.vue' | [:integrations_fe, :frontend] - 'ee/app/views/projects/integrations/jira/issues/show.html.haml' | [:integrations_fe, :frontend] - 'ee/app/assets/javascripts/integrations/zentao/issues_list/graphql/queries/get_zentao_issues.query.graphql' | [:integrations_fe, :frontend] - 'app/assets/javascripts/pages/projects/settings/integrations/show/index.js' | [:integrations_fe, :frontend] - 'ee/app/assets/javascripts/pages/groups/hooks/index.js' | [:integrations_fe, :frontend] + 'app/views/jira_connect/branches/new.html.haml' | [:import_integrate_fe, :frontend] + 'app/views/layouts/jira_connect.html.haml' | [:import_integrate_fe, :frontend] + 'app/assets/javascripts/jira_connect/branches/pages/index.vue' | [:import_integrate_fe, :frontend] + 'ee/app/views/projects/integrations/jira/issues/show.html.haml' | [:import_integrate_fe, :frontend] + 'ee/app/assets/javascripts/integrations/zentao/issues_list/graphql/queries/get_zentao_issues.query.graphql' | [:import_integrate_fe, :frontend] + 'app/assets/javascripts/pages/projects/settings/integrations/show/index.js' | [:import_integrate_fe, :frontend] + 'ee/app/assets/javascripts/pages/groups/hooks/index.js' | [:import_integrate_fe, :frontend] 'app/views/clusters/clusters/_integrations_tab.html.haml' | [:frontend, :backend] 'app/assets/javascripts/alerts_settings/graphql/fragments/integration_item.fragment.graphql' | [:frontend] 'app/assets/javascripts/filtered_search/droplab/hook_input.js' | [:frontend] @@ -263,22 +263,22 @@ RSpec.describe Tooling::Danger::ProjectHelper do context 'having specific changes' do where(:expected_categories, :patch, :changed_files) do - [:product_intelligence] | '+data-track-action' | ['components/welcome.vue'] - [:product_intelligence] | '+ data: { track_label:' | ['admin/groups/_form.html.haml'] - [:product_intelligence] | '+ Gitlab::Tracking.event' | ['dashboard/todos_controller.rb', 'admin/groups/_form.html.haml'] - [:database, :backend, :product_intelligence] | '+ count(User.active)' | ['usage_data.rb', 'lib/gitlab/usage_data.rb', 'ee/lib/ee/gitlab/usage_data.rb'] - [:database, :backend, :product_intelligence] | '+ estimate_batch_distinct_count(User.active)' | ['usage_data.rb'] - [:backend, :product_intelligence] | '+ alt_usage_data(User.active)' | ['lib/gitlab/usage_data.rb'] - [:backend, :product_intelligence] | '+ count(User.active)' | ['lib/gitlab/usage_data/topology.rb'] - [:backend, :product_intelligence] | '+ foo_count(User.active)' | ['lib/gitlab/usage_data.rb'] - [:backend] | '+ count(User.active)' | ['user.rb'] - [:integrations_be, :database, :migration] | '+ add_column :integrations, :foo, :text' | ['db/migrate/foo.rb'] - [:integrations_be, :database, :migration] | '+ create_table :zentao_tracker_data do |t|' | ['ee/db/post_migrate/foo.rb'] - [:integrations_be, :backend] | '+ Integrations::Foo' | ['app/foo/bar.rb'] - [:integrations_be, :backend] | '+ project.execute_hooks(foo, :bar)' | ['ee/lib/ee/foo.rb'] - [:integrations_be, :backend] | '+ project.execute_integrations(foo, :bar)' | ['app/foo.rb'] - [:frontend, :product_intelligence] | '+ api.trackRedisCounterEvent("foo")' | ['app/assets/javascripts/telemetry.js', 'ee/app/assets/javascripts/mr_widget.vue'] - [:frontend, :product_intelligence] | '+ api.trackRedisHllUserEvent("bar")' | ['app/assets/javascripts/telemetry.js', 'ee/app/assets/javascripts/mr_widget.vue'] + [:analytics_instrumentation] | '+data-track-action' | ['components/welcome.vue'] + [:analytics_instrumentation] | '+ data: { track_label:' | ['admin/groups/_form.html.haml'] + [:analytics_instrumentation] | '+ Gitlab::Tracking.event' | ['dashboard/todos_controller.rb', 'admin/groups/_form.html.haml'] + [:database, :backend, :analytics_instrumentation] | '+ count(User.active)' | ['usage_data.rb', 'lib/gitlab/usage_data.rb', 'ee/lib/ee/gitlab/usage_data.rb'] + [:database, :backend, :analytics_instrumentation] | '+ estimate_batch_distinct_count(User.active)' | ['usage_data.rb'] + [:backend, :analytics_instrumentation] | '+ alt_usage_data(User.active)' | ['lib/gitlab/usage_data.rb'] + [:backend, :analytics_instrumentation] | '+ count(User.active)' | ['lib/gitlab/usage_data/topology.rb'] + [:backend, :analytics_instrumentation] | '+ foo_count(User.active)' | ['lib/gitlab/usage_data.rb'] + [:backend] | '+ count(User.active)' | ['user.rb'] + [:import_integrate_be, :database, :migration] | '+ add_column :integrations, :foo, :text' | ['db/migrate/foo.rb'] + [:import_integrate_be, :database, :migration] | '+ create_table :zentao_tracker_data do |t|' | ['ee/db/post_migrate/foo.rb'] + [:import_integrate_be, :backend] | '+ Integrations::Foo' | ['app/foo/bar.rb'] + [:import_integrate_be, :backend] | '+ project.execute_hooks(foo, :bar)' | ['ee/lib/ee/foo.rb'] + [:import_integrate_be, :backend] | '+ project.execute_integrations(foo, :bar)' | ['app/foo.rb'] + [:frontend, :analytics_instrumentation] | '+ api.trackRedisCounterEvent("foo")' | ['app/assets/javascripts/telemetry.js', 'ee/app/assets/javascripts/mr_widget.vue'] + [:frontend, :analytics_instrumentation] | '+ api.trackRedisHllUserEvent("bar")' | ['app/assets/javascripts/telemetry.js', 'ee/app/assets/javascripts/mr_widget.vue'] end with_them do |