Sha256: c6390c44d5bc21ed6a92000123fd714ee312815b2523f35bb9f5c5fd7eaf7f4b

Contents?: true

Size: 798 Bytes

Versions: 11

Compression:

Stored size: 798 Bytes

Contents

require 'spec_helper'

class Context
  include CanTango::Api::Ability::User
end

# Note: This config feature is currently not used, but could potentially be of use in the future
describe CanTango::Configuration::Debug do
  let(:context) { Context.new }
  subject       { CanTango.config.debug }

  describe 'should set debug mode :on' do
    before do
      subject.set :on
    end

    its(:on?) { should be_true }
    its(:off?) { should be_false }
  end

  describe 'should set debug mode :off' do
    before do
      subject.set :on
    end

    its(:on?)   { should be_true  }
    its(:off?)  { should be_false }
  end

  describe 'debug! should set debug mode :on' do
    before do
      CanTango.debug!
    end

    its(:on?) { should be_true }
    its(:off?) { should be_false }
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
cantango-config-0.1.9.2 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.8.1 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.8 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.7 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.6 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.5 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.4 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.3 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.2 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.1 spec/cantango/configuration/debug_spec.rb
cantango-config-0.1.0 spec/cantango/configuration/debug_spec.rb