Sha256: e1fad9ce82892a4ed3c74e4fb80929cdcf40715358c41e89da8c9492fe0f525e
Contents?: true
Size: 616 Bytes
Versions: 6
Compression:
Stored size: 616 Bytes
Contents
require 'spec_helper' describe GreenFlag::Admin::RuleListsController do let(:feature) { GreenFlag::Feature.create(code: 'asdf') } describe '#show' do subject { get :show, feature_id: feature.id, format: 'js' } it { should be_successful } end describe '#update' do let(:empty_rules_json) { [] } subject do post :update, feature_id: feature.id, format: 'js', '_json' => empty_rules_json end it { should be_successful } it 'sends the rules to a model' do expect(GreenFlag::Rule).to receive(:set_rules!).with(feature.id, []) subject end end end
Version data entries
6 entries across 6 versions & 1 rubygems