aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xtests/test_bindfs.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/test_bindfs.rb b/tests/test_bindfs.rb
index 54521f0..6c3fb0b 100755
--- a/tests/test_bindfs.rb
+++ b/tests/test_bindfs.rb
@@ -73,9 +73,9 @@ end
root_testenv("", :title => "--create-as-user should be default for root") do
chmod(0777, 'src')
- `su -c 'touch mnt/file' nobody`
- `su -c 'mkdir mnt/dir' nobody`
- `su -c 'ln -sf /tmp/foo mnt/lnk' nobody`
+ `sudo -u nobody -g nogroup touch mnt/file`
+ `sudo -u nobody -g nogroup mkdir mnt/dir`
+ `sudo -u nobody -g nogroup ln -sf /tmp/foo mnt/lnk`
assert { File.stat('mnt/file').uid == nobody_uid }
assert { File.stat('mnt/file').gid == nogroup_gid }