(testdir)
| 87 | stat = cephfs.sync_fs() |
| 88 | |
| 89 | def test_fsync(testdir): |
| 90 | fd = cephfs.open(b'file-1', 'w', 0o755) |
| 91 | cephfs.write(fd, b"asdf", 0) |
| 92 | stat = cephfs.fsync(fd, 0) |
| 93 | cephfs.write(fd, b"qwer", 0) |
| 94 | stat = cephfs.fsync(fd, 1) |
| 95 | cephfs.close(fd) |
| 96 | #sync on non-existing fd (assume fd 12345 is not exists) |
| 97 | assert_raises(libcephfs.Error, cephfs.fsync, 12345, 0) |
| 98 | |
| 99 | def test_directory(testdir): |
| 100 | cephfs.mkdir(b"/temp-directory", 0o755) |
nothing calls this directly
no test coverage detected