test/hirb_test.rb in hirb-0.7.2 vs test/hirb_test.rb in hirb-0.7.3

- old
+ new

@@ -4,21 +4,21 @@ before_all { Hirb.config_files = nil } before { Hirb.config = nil } it "config converts yaml when config file exists" do yaml_data = {:blah=>'blah'} - File.stubs('exists?').returns(true) + File.stubs('exist?').returns(true) Hirb.config_files = ['ok'] - YAML::expects(:load_file).returns(yaml_data) + YAML.expects(:load_file).returns(yaml_data) Hirb.config.should == yaml_data end - + it "config defaults to hash when no config file" do - File.stubs('exists?').returns(false) + File.stubs('exist?').returns(false) Hirb.config.should == {} end - + it "config reloads if given explicit reload" do Hirb.config Hirb.expects(:read_config_file).returns({}) Hirb.config(true) end @@ -34,6 +34,6 @@ Hirb.config_files = nil home = ENV.delete('HOME') Hirb.config_files[0].class.should == String ENV["HOME"] = home end -end \ No newline at end of file +end