WebAssembly / WASI

WebAssembly System Interface
Other
4.71k stars 240 forks source link

Where is "Wasmtime's WASI Preview 2 test suite"? #602

Closed igrep closed 1 month ago

igrep commented 1 month ago

According to the README of WASI Preview 2,

The portability criteria of the WASI Preview 2 proposals were met by the
following implementations, which were demonstrated to be interoperable by
each passing [Wasmtime's WASI Preview 2 test suite][test-suite].

But the URL of [test-suite] is not specified.

I tried to fix by myself, but failed to find the actual URL of "Wasmtime's WASI Preview 2 test suite". There are several candidate directories (below), but both of them don't look so as far as I browsed.

pchickey commented 1 month ago

Sorry I missed filling in that URL!

The test suite is indeed in the test-programs crate, which produces a large number of binaries: https://github.com/bytecodealliance/wasmtime/tree/main/crates/test-programs/src/bin . There are some preview2_ specific tests in there which consume p2 imports directly, and then there is the much larger set of preview1_ tests which are adapted from p1 to p2 imports using the component adapter: https://github.com/bytecodealliance/wasmtime/tree/main/crates/wasi-preview1-component-adapter. Linking a p1 module with the adapter into a component is implemented by wasm-tools component new.

igrep commented 1 month ago

Okay, so how about filling some documents of https://github.com/bytecodealliance/wasmtime/tree/main/crates/test-programs before adding the link to it?