Page MenuHomeFreeBSD

Fix usr.bin.truncate.truncate_test.bad_truncate with ZFS /tmp.
ClosedPublic

Authored by asomers on Jan 11 2016, 9:37 PM.
Tags
None
Referenced Files
Unknown Object (File)
Jan 4 2024, 5:49 PM
Unknown Object (File)
Jan 4 2024, 5:49 PM
Unknown Object (File)
Jan 4 2024, 5:49 PM
Unknown Object (File)
Jan 4 2024, 5:49 PM
Unknown Object (File)
Jan 4 2024, 3:35 PM
Unknown Object (File)
Dec 27 2023, 9:56 AM
Unknown Object (File)
Dec 27 2023, 9:56 AM
Unknown Object (File)
Dec 23 2023, 11:09 AM
Subscribers

Details

Summary

Use simmutable instead of uimmutable in the bad_truncate test. The former
is supported by both ZFS and UFS, but the latter only by UFS.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

asomers retitled this revision from to Fix usr.bin.truncate.truncate_test.bad_truncate with ZFS /tmp..
asomers updated this object.
asomers edited the test plan for this revision. (Show Details)
asomers added a reviewer: jilles.

This adds a requirement that the test be run as root and that securelevel be -1 or 0, which may not be desirable. To prevent compatibility problems, a line

TEST_METADATA.truncate_test+=  required_user="root"

should be added to usr.bin/truncate/tests/Makefile.

Alternatively, file permissions (chmod 444) instead of file flags could be used. This requires

TEST_METADATA.truncate_test+=  required_user="unprivileged"

and the expected error message should be Permission denied instead of Operation not permitted.

asomers edited edge metadata.

Address feedback from jilles: Use permissions instead of flags in bad_truncate

jilles edited edge metadata.

Looks good to me.

This revision is now accepted and ready to land.Jan 19 2016, 10:02 PM
This revision was automatically updated to reflect the committed changes.