summaryrefslogtreecommitdiff
path: root/spec/lib/gitlab/usage/metrics/instrumentations/service_ping_features_metric_spec.rb
blob: 40e9b96287853c309111379def89469722894a71 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# frozen_string_literal: true

require 'spec_helper'

RSpec.describe Gitlab::Usage::Metrics::Instrumentations::ServicePingFeaturesMetric do
  using RSpec::Parameterized::TableSyntax

  where(:usage_ping_features_enabled, :expected_value) do
    true  | true
    false | false
  end

  with_them do
    before do
      stub_application_setting(usage_ping_features_enabled: usage_ping_features_enabled)
    end

    it_behaves_like 'a correct instrumented metric value', { time_frame: 'none' }
  end
end