Sha256: 2009f2c42217612552f4be720b57b0010c773049df128ca017b3a5f3f35ae4e5

Contents?: true

Size: 709 Bytes

Versions: 19

Compression:

Stored size: 709 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/spec_helper')

describe "Configliere" do
  it 'creates a new param on new' do
    mock_param = 'mock_param'
    Configliere::Param.should_receive(:new).with(:this => :that).and_return(mock_param)
    Configliere.new(:this => :that).should == mock_param
  end
  it 'creates a global variable Settings' do
    Settings.class.should == Configliere::Param
  end
  it 'creates a glocal method Settings' do
    Settings.should_receive(:defaults).with(:foo => :bar)
    Settings(:foo => :bar)
  end

  it 'requires modules with use' do
    lambda{ Configliere.use(:param, :foo) }.should raise_error(LoadError, 'no such file to load -- configliere/foo')
  end

end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
configliere-0.3.4 spec/configliere_spec.rb
configliere-0.3.3 spec/configliere_spec.rb
configliere-0.2.3 spec/configliere_spec.rb
configliere-0.3.2 spec/configliere_spec.rb
configliere-0.3.1 spec/configliere_spec.rb
configliere-0.3.0 spec/configliere_spec.rb
configliere-0.2.2 spec/configliere_spec.rb
configliere-0.2.1 spec/configliere_spec.rb
configliere-0.1.1 spec/configliere_spec.rb
configliere-0.1.0 spec/configliere_spec.rb
configliere-0.0.9 spec/configliere_spec.rb
configliere-0.0.8 spec/configliere_spec.rb
configliere-0.0.7 spec/configliere_spec.rb
configliere-0.0.6 spec/configliere_spec.rb
configliere-0.0.5 spec/configliere_spec.rb
configliere-0.0.4 spec/configliere_spec.rb
configliere-0.0.3 spec/configliere_spec.rb
configliere-0.0.2 spec/configliere_spec.rb
configliere-0.0.1 spec/configliere_spec.rb