diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2017-10-26 20:10:40 +0100 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2017-12-16 20:41:14 +0000 |
commit | 9354546bc9f78ebfd10298d1915bbaa4db266330 (patch) | |
tree | 888b6ea3956e9f650c1245d809c164f9afc0200f | |
parent | Improve permissions tests on rename (diff) | |
download | netfs-9354546bc9f78ebfd10298d1915bbaa4db266330.tar.bz2 netfs-9354546bc9f78ebfd10298d1915bbaa4db266330.tar.xz netfs-9354546bc9f78ebfd10298d1915bbaa4db266330.zip |
Improve permissions tests on mknod
-rw-r--r-- | netfs/unittests/testCore.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/netfs/unittests/testCore.cpp b/netfs/unittests/testCore.cpp index 56c695e..3e64d40 100644 --- a/netfs/unittests/testCore.cpp +++ b/netfs/unittests/testCore.cpp @@ -364,6 +364,9 @@ BOOST_AUTO_TEST_CASE( mknod ) BOOST_REQUIRE_EQUAL(st.st_mode, 0600 | S_IFIFO); BOOST_REQUIRE_EQUAL(fuse->unlink("/nod"), 0); BOOST_REQUIRE_EQUAL(fuse->unlink("/nod"), -ENOENT); + disableWriteOnDir(fuse, "/"); + BOOST_REQUIRE_EQUAL(fuse->mknod("/nod", 0600 | S_IFIFO, 0), -EACCES); + enableWriteOnDir(fuse, "/"); } BOOST_AUTO_TEST_CASE( renameToDir ) |