-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
*nix test for opening /dev/* #514
Labels
wasi:tests
Issues pertaining to WASI tests in Wasmtime
Comments
erikrose
added a commit
to erikrose/wasmtime
that referenced
this issue
Jan 28, 2025
Fixes bytecodealliance#514, but CI is grumpy and I have questions. Both the sync and async variants run by `cargo test -p wasi-common preview1_device_read` work and are valid. However, `foreach_preview1!(assert_test_exists)` fails its assertions when I run `ci/run-tests.sh` unless I repeat my tests in `wasi` (commented out here) as well as `wasi-common`. Is that the intent? I'm not sure what value such repetition has for this test. Perhaps I'm adding tests in the wrong place altogether. I welcome any illumination! Note that I've hard-coded a "/dev" preopen into the test harnesses temporarily. Once I'm sure I'm adding to the right set of tests, I'll refactor to pass it only for this new one.
erikrose
added a commit
to erikrose/wasmtime
that referenced
this issue
Jan 28, 2025
Fixes bytecodealliance#514, but CI is grumpy and I have questions. Both the sync and async variants run by `cargo test -p wasi-common preview1_device_read` work and are valid. However, `foreach_preview1!(assert_test_exists)` fails its assertions when I run `ci/run-tests.sh` unless I repeat my tests in `wasi` (commented out here) as well as `wasi-common`. Is that the intent? I'm not sure what value such repetition has for this test. Perhaps I'm adding tests in the wrong place altogether. I welcome any illumination! Note that I've hard-coded a "/dev" preopen into the test harnesses temporarily. Once I'm sure I'm adding to the right set of tests, I'll refactor to pass it only for this new one.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Assuming that the Wasm app was given necessary capabilities (in this case, access to
/dev/
dir), ensure that it is possible to properly open misc devices such as:/dev/random
/dev/urandom
/dev/zero
/dev/null
Relevant PRs that spotted and/or fixed the bug:
The text was updated successfully, but these errors were encountered: