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

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

require 'spec_helper'

describe Constraints::FeatureConstrainer do
  describe '#matches' do
    it 'calls Feature.enabled? with the correct arguments' do
      expect(Feature).to receive(:enabled?).with(:feature_name, "an object", default_enabled: true)

      described_class.new(:feature_name, "an object", default_enabled: true).matches?(double('request'))
    end
  end
end