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: 42efc164f81211ce9b94d81f851ad27f12d94568 (plain)
1
2
3
4
5
6
7
8
9
10
11
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