summaryrefslogtreecommitdiffstats
path: root/test/util
diff options
context:
space:
mode:
authorMarkus Roberts <Markus@reality.com>2010-06-09 17:47:39 -0700
committertest branch <puppet-dev@googlegroups.com>2010-02-17 06:50:53 -0800
commit2396ebac9021eaa4a2983e60902c04cc9e0db0ee (patch)
tree05015dc5d67aca35dd235a6229fb360ecb6b68e9 /test/util
parent8128311690a25d864087a7aee31b233a459345fd (diff)
Use the 'root' feature rather than directly checking the uid
Jesse fixed all these but David and others moved them and introduced some more so...
Diffstat (limited to 'test/util')
-rwxr-xr-xtest/util/settings.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/util/settings.rb b/test/util/settings.rb
index e94778e2a..272ced9f5 100755
--- a/test/util/settings.rb
+++ b/test/util/settings.rb
@@ -359,7 +359,7 @@ yay = /a/path
user = nonrootuser()
group = nonrootgroup()
- if Puppet::Util::SUIDManager.uid == 0
+ if Puppet.features.root?
args[:owner] = user.name
args[:group] = group.name
end
@@ -375,7 +375,7 @@ yay = /a/path
assert_equal(mode, filemode(path), "Modes are not equal")
# OS X is broken in how it chgrps files
- if Puppet::Util::SUIDManager.uid == 0
+ if Puppet.features.root?
assert_equal(user.uid, File.stat(path).uid, "UIDS are not equal")
case Facter["operatingsystem"].value
@@ -399,7 +399,7 @@ yay = /a/path
user = nonrootuser()
group = nonrootgroup()
- if Puppet::Util::SUIDManager.uid == 0
+ if Puppet.features.root?
args[:owner] = user.name
args[:group] = group.name
end
@@ -414,7 +414,7 @@ yay = /a/path
# OS X and *BSD is broken in how it chgrps files
- if Puppet::Util::SUIDManager.uid == 0
+ if Puppet.features.root?
assert_equal(user.uid, File.stat(path).uid, "UIDS are not equal")
case Facter["operatingsystem"].value