This commit is contained in:
James Turnbull 2010-01-30 11:10:16 +11:00
Родитель b7b7a1c3ca
Коммит 55f6239d8e
2 изменённых файлов: 6 добавлений и 6 удалений

Просмотреть файл

@ -154,7 +154,7 @@ end
module PuppetTest
include PuppetTest::Support::Utils
def self.fakedata(dir,pat='*')
def fakedata(dir,pat='*')
glob = "#{basedir}/test/#{dir}/#{pat}"
files = Dir.glob(glob,File::FNM_PATHNAME)
raise Puppet::DevError, "No fakedata matching #{glob}" if files.empty?

Просмотреть файл

@ -463,7 +463,7 @@ yay = /a/path
def test_correct_type_assumptions
file = Puppet::Util::Settings::FileSetting
element = Puppet::Util::Settings::Setting
setting = Puppet::Util::Settings::Setting
bool = Puppet::Util::Settings::BooleanSetting
# We have to keep these ordered, unfortunately.
@ -472,8 +472,8 @@ yay = /a/path
["true", bool],
[true, bool],
["false", bool],
["server", element],
["http://$server/yay", element],
["server", setting],
["http://$server/yay", setting],
["$server/yayness", file],
["$server/yayness.conf", file]
].each do |ary|
@ -483,7 +483,7 @@ yay = /a/path
assert_nothing_raised {
config.setdefaults(:yayness, name => { :default => value, :desc => name.to_s})
}
elem = config.element(name)
elem = config.setting(name)
assert_instance_of(type, elem,
"%s got created as wrong type" % value.inspect)
@ -529,7 +529,7 @@ yay = /a/path
assert_nothing_raised do
config.setdefaults :test, :blocktest => {:default => "yay", :desc => "boo", :hook => proc { |value| testing = value }}
end
elem = config.element(:blocktest)
elem = config.setting(:blocktest)
assert_nothing_raised do
assert_equal("yay", elem.value)