Sha256: 63faaeb37ee53b8ee6c14904b01e86f7411bc5a2b4293935ae91eaeed618df5e
Contents?: true
Size: 897 Bytes
Versions: 21
Compression:
Stored size: 897 Bytes
Contents
require 'rspec' require 'cantango' require 'fixtures/models' @user = User.new('kris', 'kris@gmail.com') class CanTango::CustomAbility < CanTango::Ability def initialize candidate, options = {} 'custom' end end describe CanTango::Configuration do describe 'clear!' do subject { CanTango.config } before do subject.roles.exclude :user subject.role_groups.exclude :admins subject.clear! end specify { subject.roles.excluded.should be_empty } specify { subject.role_groups.excluded.should be_empty } end describe "configure DSL" do before(:all) { CanTango.configure do |config| CanTango.config.engines.each do |engine| engine.set :off end end } CanTango.config.engines.each do |engine| specify { engine.on?.should be_false} specify { engine.off?.should be_true} end end end
Version data entries
21 entries across 21 versions & 1 rubygems