diff options
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/test_bindfs.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/test_bindfs.rb b/tests/test_bindfs.rb index 01327b5..69ca6e0 100755 --- a/tests/test_bindfs.rb +++ b/tests/test_bindfs.rb @@ -762,6 +762,16 @@ testenv("", :title => "mntdir with newline", :mntdir_name => "a\nb") do assert { File.exist?("a\nb/f") } end +# Pull Request #73 +if `uname`.strip == 'Linux' && `which unshare` != '' + root_testenv("--gid-offset=10000", :title => "setgid and gid-offset") do + system("chmod g+s src") + system("unshare --map-root-user --user #{$nobody} mkdir mnt/dir") + assert { File.stat("src/dir").gid == 0 } + assert { File.stat("mnt/dir").gid == 10000 } + end +end + if `uname`.strip != 'FreeBSD' # -o dev is not supported on FreeBSD root_testenv("-odev") do system("mknod mnt/zero c 1 5") |