spec/confstruct/configuration_spec.rb in confstruct-1.0.1 vs spec/confstruct/configuration_spec.rb in confstruct-1.0.2

- old
+ new

@@ -2,20 +2,20 @@ describe Confstruct::Configuration do it "should initialize empty" do conf = Confstruct::Configuration.new - conf.is_a?(Hash).should be_true - conf.is_a?(Confstruct::Configuration).should be_true + conf.is_a?(Hash).should be_truthy + conf.is_a?(Confstruct::Configuration).should be_truthy conf.should == {} end it "should initialize properly from a nested hash with string keys" do x = { 'a' => { 'b' => 'c' } } conf = Confstruct::Configuration.new(x) - conf.is_a?(Hash).should be_true - conf.is_a?(Confstruct::Configuration).should be_true + conf.is_a?(Hash).should be_truthy + conf.is_a?(Confstruct::Configuration).should be_truthy conf[:a][:b].should == 'c' conf['a']['b'].should == 'c' conf.a.b.should == 'c' end @@ -135,10 +135,10 @@ @config.reset_defaults! @config.should == @defaults end it "should call #after_config! when configuration is complete" do - postconfigurator = RSpec::Mocks::Mock.new('after_config!') + postconfigurator = double('after_config!') postconfigurator.should_receive(:configured!).once.with(@config) def @config.after_config! obj obj.project.should == 'other-project' obj.mock.configured!(obj) end