mirror of
https://github.com/linux-apfs/apfstests.git
synced 2026-05-01 15:01:44 -07:00
xfstests: generic/193 runs tests in wrong location
generic/193 runs the test in $here - the root of the xfstests source tree/installation. IOWs, it doesn't test the filesystem on either the TEST_DIR or SCRATCH_MNT, and so it not testing the filesystem we think it is testing. Bad. Fixing this is the majority of the change - introducing $test_root and $test_user for the files with different owners, and then redirecting error output and filtering the output appropriately. And then add checks that truncate clears the suid/sgid bits appropriately, something that has never been tested on XFS (and likely other filesystems) so will cause kernels between 3.1 and 3.9 to assert fail as Dave Jones has recently reported. Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Ben Myers <bpm@sgi.com> Signed-off-by: Ben Myers <bpm@sgi.com>
This commit is contained in:
+15
-2
@@ -8,14 +8,14 @@ user: chown root owned file to root (should fail)
|
||||
chown: changing ownership of `test.root': Operation not permitted
|
||||
user: chown qa_user owned file to qa_user (should succeed)
|
||||
user: chown qa_user owned file to root (should fail)
|
||||
chown: changing ownership of `test.fsgqa': Operation not permitted
|
||||
chown: changing ownership of `test.user': Operation not permitted
|
||||
|
||||
testing ATTR_GID
|
||||
|
||||
user: chgrp root owned file to root (should fail)
|
||||
chgrp: changing group of `test.root': Operation not permitted
|
||||
user: chgrp qa_user owned file to root (should fail)
|
||||
chgrp: changing group of `test.fsgqa': Operation not permitted
|
||||
chgrp: changing group of `test.user': Operation not permitted
|
||||
user: chgrp root owned file to qa_user (should fail)
|
||||
chgrp: changing group of `test.root': Operation not permitted
|
||||
user: chgrp qa_user owned file to qa_user (should succeed)
|
||||
@@ -42,6 +42,19 @@ after: -rw-r-xr--
|
||||
with user+group exec perm
|
||||
before: -rwsr-sr--
|
||||
after: -rwxr-xr--
|
||||
check that suid/sgid bits are cleared after successful truncate...
|
||||
with no exec perm
|
||||
before: -rwSr-Sr--
|
||||
after: -rw-r-Sr--
|
||||
with user exec perm
|
||||
before: -rwsr-Sr--
|
||||
after: -rwxr-Sr--
|
||||
with group exec perm
|
||||
before: -rwSr-sr--
|
||||
after: -rw-r-xr--
|
||||
with user+group exec perm
|
||||
before: -rwsr-sr--
|
||||
after: -rwxr-xr--
|
||||
|
||||
testing ATTR_*TIMES_SET
|
||||
|
||||
|
||||
Reference in New Issue
Block a user