diff options
| author | Henry Gressmann <mail@henrygressmann.de> | 2023-12-12 09:14:26 +0100 |
|---|---|---|
| committer | Henry Gressmann <mail@henrygressmann.de> | 2023-12-12 09:14:26 +0100 |
| commit | 1663131fb135abf96e4e68a5f872d5cb282ec5e5 (patch) | |
| tree | a262d485b982531f2a64336039c880c69b0484d3 /crates/wasm-testsuite/README.md | |
| parent | cdf44f4852ed6f52deb9823331f26e0bbaf07732 (diff) | |
docs: update documentation
Signed-off-by: Henry Gressmann <mail@henrygressmann.de>
Diffstat (limited to 'crates/wasm-testsuite/README.md')
| -rw-r--r-- | crates/wasm-testsuite/README.md | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/crates/wasm-testsuite/README.md b/crates/wasm-testsuite/README.md new file mode 100644 index 0000000..c3dcde2 --- /dev/null +++ b/crates/wasm-testsuite/README.md @@ -0,0 +1,20 @@ +# `wasm-testsuite` + +This crate embeds the latest version of the [WebAssembly Test Suite](https://github.com/WebAssembly/spec/tree/main/test). It is currently mainly used for testing the `tinywasm-parser` crate. Check out the [documentation](https://docs.rs/wasm-testsuite) for more information. + +## Usage + +```rust +use wasm_testsuite::{MVP_TESTS, get_test_wast}; + +wasm_testsuite::MVP_TESTS.iter().for_each(|test| { + let wast_bytes = get_test_wast(test).expect("Failed to get wast bytes"); + let wast = std::str::from_utf8(&wast).expect("failed to convert wast to utf8"); + + // Do something with the wast (e.g. parse it using the `wast` crate) +}); +``` + +## License + +This crate is licensed under the [Apache License, Version 2.0](https://github.com/WebAssembly/spec/blob/main/test/LICENSE).
\ No newline at end of file |
