]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Begin a fuse(4) test suite
authorasomers <asomers@FreeBSD.org>
Fri, 1 Mar 2019 23:53:05 +0000 (23:53 +0000)
committerasomers <asomers@FreeBSD.org>
Fri, 1 Mar 2019 23:53:05 +0000 (23:53 +0000)
commit88e12de1fd65315ef05f969d21a3ef9e5103d9d5
treec0fc1203e93dc6a0be3f839691e47bd806c568c7
parent3ae72efead270c64e5f7381cd1dd9cf2e498cb76
Begin a fuse(4) test suite

It only tests the kernel portion of fuse, not the userspace portion (which
comes from sysutils/fusefs-libs).  The kernel-userspace interface is
de-facto standardized, and this test suite seeks to validate FreeBSD's
implementation.

It uses GoogleMock to substitute for a userspace daemon and validate the
kernel's behavior in response to filesystem access.  GoogleMock is
convenient because it can validate the order, number, and arguments of each
operation, and return canned responses.

But that also means that the test suite must use GoogleTest, since
GoogleMock is incompatible with atf-c++ and atf.test.mk does not allow C++
programs to use atf-c.

This commit adds the first 10 test cases out of an estimated 130 total.

PR: 235775, 235773
Sponsored by: The FreeBSD Foundation
etc/mtree/BSD.tests.dist
tests/sys/fs/Makefile
tests/sys/fs/fuse/Makefile [new file with mode: 0644]
tests/sys/fs/fuse/getattr.cc [new file with mode: 0644]
tests/sys/fs/fuse/lookup.cc [new file with mode: 0644]
tests/sys/fs/fuse/mockfs.cc [new file with mode: 0644]
tests/sys/fs/fuse/mockfs.hh [new file with mode: 0644]
tests/sys/fs/fuse/utils.cc [new file with mode: 0644]
tests/sys/fs/fuse/utils.hh [new file with mode: 0644]