summaryrefslogtreecommitdiffstats
path: root/test/lib/puppettest/support
diff options
context:
space:
mode:
authorluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2006-10-17 21:38:30 +0000
committerluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2006-10-17 21:38:30 +0000
commit95f2fe70bf63791fb691d539281f5cfbfd1fb664 (patch)
treebde480ce5ada8ea2abbc5fecf8f5c9aa3ca2aabf /test/lib/puppettest/support
parent86dae84dad4cd5688029c398109b15b6074cf3c4 (diff)
downloadpuppet-95f2fe70bf63791fb691d539281f5cfbfd1fb664.tar.gz
puppet-95f2fe70bf63791fb691d539281f5cfbfd1fb664.tar.xz
puppet-95f2fe70bf63791fb691d539281f5cfbfd1fb664.zip
Ported mount over to using providers
git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1801 980ebf18-57e1-0310-9a29-db15c13687c0
Diffstat (limited to 'test/lib/puppettest/support')
-rw-r--r--test/lib/puppettest/support/utils.rb13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/lib/puppettest/support/utils.rb b/test/lib/puppettest/support/utils.rb
index ea2d5483c..c7d54d5e6 100644
--- a/test/lib/puppettest/support/utils.rb
+++ b/test/lib/puppettest/support/utils.rb
@@ -142,6 +142,19 @@ module PuppetTest
return comp
end
+
+ def setme
+ # retrieve the user name
+ id = %x{id}.chomp
+ if id =~ /uid=\d+\(([^\)]+)\)/
+ @me = $1
+ else
+ puts id
+ end
+ unless defined? @me
+ raise "Could not retrieve user name; 'id' did not work"
+ end
+ end
end
# $Id$