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

search_counter_spec.rb « usage_data_counters « gitlab « lib « spec - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 50a9f980dc72d6a1621613632ecdab7193d8f8d1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
# frozen_string_literal: true

require 'spec_helper'

describe Gitlab::UsageDataCounters::SearchCounter, :clean_gitlab_redis_shared_state do
  it 'increments counter and return the total count' do
    expect(described_class.total_navbar_searches_count).to eq(0)

    2.times { described_class.increment_navbar_searches_count }

    expect(described_class.total_navbar_searches_count).to eq(2)
  end
end