diff options
| author | luke <luke@980ebf18-57e1-0310-9a29-db15c13687c0> | 2007-01-02 20:23:27 +0000 |
|---|---|---|
| committer | luke <luke@980ebf18-57e1-0310-9a29-db15c13687c0> | 2007-01-02 20:23:27 +0000 |
| commit | 50965c7a0f4f9cf342c469f8d586d0a2f2b4efa8 (patch) | |
| tree | e2fc3e9333e1dd7877ae00f17959cf50cdc42be1 | |
| parent | 373f1770de9a6f3c741832cc86f0bcdc30a14bce (diff) | |
| download | puppet-50965c7a0f4f9cf342c469f8d586d0a2f2b4efa8.tar.gz puppet-50965c7a0f4f9cf342c469f8d586d0a2f2b4efa8.tar.xz puppet-50965c7a0f4f9cf342c469f8d586d0a2f2b4efa8.zip | |
Changing "sourcematch" to "sourceselect"
git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2017 980ebf18-57e1-0310-9a29-db15c13687c0
| -rw-r--r-- | lib/puppet/type/pfile.rb | 4 | ||||
| -rwxr-xr-x | test/types/filesources.rb | 8 |
2 files changed, 6 insertions, 6 deletions
diff --git a/lib/puppet/type/pfile.rb b/lib/puppet/type/pfile.rb index a9254e5ea..dabfdce29 100644 --- a/lib/puppet/type/pfile.rb +++ b/lib/puppet/type/pfile.rb @@ -191,7 +191,7 @@ module Puppet newvalues(:true, :false) end - newparam(:sourcematch) do + newparam(:sourceselect) do desc "Whether to copy all valid sources, or just the first one." defaultto :first @@ -874,7 +874,7 @@ module Puppet self.newchild(name, false, args) }.reject {|c| c.nil? } - if self[:sourcematch] == :first + if self[:sourceselect] == :first return result end end diff --git a/test/types/filesources.rb b/test/types/filesources.rb index 49ef73fe2..1a4c61793 100755 --- a/test/types/filesources.rb +++ b/test/types/filesources.rb @@ -936,7 +936,7 @@ class TestFileSources < Test::Unit::TestCase assert_equal("yayness\n", File.read(newfile)) end - def test_sourcematch + def test_sourceselect dest = tempfile() sources = [] 2.times { |i| @@ -961,7 +961,7 @@ class TestFileSources < Test::Unit::TestCase obj = Puppet::Type.newfile(:path => dest, :recurse => true, :source => sources) - assert_equal(:first, obj[:sourcematch], "sourcematch has the wrong default") + assert_equal(:first, obj[:sourceselect], "sourceselect has the wrong default") # First, make sure we default to just copying file1 assert_apply(obj) @@ -970,9 +970,9 @@ class TestFileSources < Test::Unit::TestCase assert(FileTest.exists?(file3), "File from source 1 was not copied") assert_equal("0", File.read(file3), "file3 got wrong contents") - # Now reset sourcematch + # Now reset sourceselect assert_nothing_raised do - obj[:sourcematch] = :all + obj[:sourceselect] = :all end File.unlink(file1) File.unlink(file3) |
