summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2006-06-13 21:23:58 +0000
committerluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2006-06-13 21:23:58 +0000
commit1dfd55408d3a9f5c609ee562d0e948c15c5629fb (patch)
tree617a1b21372c610b4ad3f79e7d7b89ae33bd1365 /test
parentdf340d6cd176f375df94e35ed2efc48b622348f2 (diff)
Fixing packaging to deal with the fact that yum exits with 0 exit code even when it is told to install a non-existent package.
git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1263 980ebf18-57e1-0310-9a29-db15c13687c0
Diffstat (limited to 'test')
-rw-r--r--test/types/package.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/types/package.rb b/test/types/package.rb
index 1c18fa628..3e76960b4 100644
--- a/test/types/package.rb
+++ b/test/types/package.rb
@@ -196,7 +196,8 @@ class TestPackages < Test::Unit::TestCase
mkpkgs { |pkg|
next unless pkg.respond_to? :latest
assert_nothing_raised {
- assert(pkg.latest, "Package did not return value for 'latest'")
+ assert(pkg.latest,
+ "Package %s did not return value for 'latest'" % pkg.name)
}
}
end
@@ -224,7 +225,7 @@ class TestPackages < Test::Unit::TestCase
pkg.retrieve
}
- if pkg.insync?
+ if pkg.insync? or pkg.is(:ensure) != :absent
Puppet.notice "Test package %s is already installed; please choose a different package for testing" % pkg
next
end