Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-06-10 00:09:51 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-06-10 00:09:51 +0300
commite374f6b2297582fde956350e92c19d1ae93ddfc8 (patch)
tree30be153d2883438955cfbf0d576052adc5875f67 /spec/config
parent1268cfeaf73a73c5593f13639530513716826e2b (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/config')
-rw-r--r--spec/config/metrics/every_metric_definition_spec.rb38
1 files changed, 38 insertions, 0 deletions
diff --git a/spec/config/metrics/every_metric_definition_spec.rb b/spec/config/metrics/every_metric_definition_spec.rb
new file mode 100644
index 00000000000..7492d6cdae5
--- /dev/null
+++ b/spec/config/metrics/every_metric_definition_spec.rb
@@ -0,0 +1,38 @@
+# frozen_string_literal: true
+
+require 'spec_helper'
+
+RSpec.describe 'Every metric definition', feature_category: :service_ping, unless: Gitlab.ee? do
+ include_examples "every metric definition" do
+ let(:ce_key_paths_mistakenly_defined_in_ee) do
+ %w[
+ counts.assignee_lists
+ counts.milestone_lists
+ counts.projects_with_repositories_enabled
+ counts.protected_branches
+ ].freeze
+ end
+
+ let(:ee_key_paths_mistakenly_defined_in_ce) do
+ %w[
+ counts.operations_dashboard_default_dashboard
+ counts.operations_dashboard_users_with_projects_added
+ usage_activity_by_stage.create.projects_imported_from_github
+ usage_activity_by_stage.monitor.operations_dashboard_users_with_projects_added
+ usage_activity_by_stage.plan.epics
+ usage_activity_by_stage.plan.label_lists
+ usage_activity_by_stage_monthly.create.projects_imported_from_github
+ usage_activity_by_stage_monthly.create.protected_branches
+ usage_activity_by_stage_monthly.monitor.operations_dashboard_users_with_projects_added
+ usage_activity_by_stage_monthly.plan.epics
+ usage_activity_by_stage_monthly.plan.label_lists
+ usage_activity_by_stage_monthly.secure.sast_pipeline
+ usage_activity_by_stage_monthly.secure.secret_detection_pipeline
+ ].freeze
+ end
+
+ let(:expected_metric_files_key_paths) do
+ metric_files_key_paths - ee_key_paths_mistakenly_defined_in_ce + ce_key_paths_mistakenly_defined_in_ee
+ end
+ end
+end