Sha256: 5c5e822d7e08617c263c66d171e47267740c0c7fa43dea71070797c56c657a07
Contents?: true
Size: 741 Bytes
Versions: 1
Compression:
Stored size: 741 Bytes
Contents
require File.join(File.dirname(__FILE__), 'test_helper') class Boson::RepoTest < Test::Unit::TestCase context "config" do before(:all) { reset } before(:each) { @repo = Boson::Repo.new(File.dirname(__FILE__)) } test "reloads config when passed true" do @repo.config.object_id.should_not == @repo.config(true).object_id end test "reads existing config correctly" do expected_hash = {:commands=>{'c1'=>{}}, :libraries=>{}} YAML.expects(:load_file).returns(expected_hash) @repo.config[:commands]['c1'].should == {} end test "ignores nonexistent file and sets config defaults" do assert @repo.config[:commands].is_a?(Hash) && @repo.config[:libraries].is_a?(Hash) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
boson-0.0.1 | test/repo_test.rb |