The Go stdlib has a great test suite in testing/fstest to validate the implementation of file-system-like types. I added a wasi.FS function which wraps a wasi.System and creates an adapter between the two interfaces so we can use the test suite to verify the behavior of WASI systems.
The tests highlighted one issue with the selection of open flags in path_open, which is fixed here as well.
The Go stdlib has a great test suite in
testing/fstest
to validate the implementation of file-system-like types. I added awasi.FS
function which wraps awasi.System
and creates an adapter between the two interfaces so we can use the test suite to verify the behavior of WASI systems.The tests highlighted one issue with the selection of open flags in path_open, which is fixed here as well.