I'm not sure which behavior is the expected behavior, but it seems that the test executable requires external file access to run if it is built with the latest (DEVELOPMENT-SNAPSHOT-2024-03-22-a-wasm) toolchain.
$ mkdir wasm-test-example
$ cd wasm-test-example
$ swift package init --type library -name WasmTestExample
$ swift build --build-tests --experimental-swift-sdk DEVELOPMENT-SNAPSHOT-2024-03-20-a-wasm
$ wasmtime .build/debug/WasmTestExamplePackageTests.wasm
Test Suite 'All tests' started at
Test Suite 'testBundle.xctest' started at
Test Suite 'WasmTestExampleTests' started at
Test Case 'WasmTestExampleTests.testExample' started at
Test Case 'WasmTestExampleTests.testExample' passed (0.0 seconds)
Test Suite 'WasmTestExampleTests' passed at
Executed 1 test, with 0 failures (0 unexpected) in 0.0 (0.0) seconds
Test Suite 'testBundle.xctest' passed at
Executed 1 test, with 0 failures (0 unexpected) in 0.0 (0.0) seconds
Test Suite 'All tests' passed at
Executed 1 test, with 0 failures (0 unexpected) in 0.0 (0.0) seconds
Description
I'm not sure which behavior is the expected behavior, but it seems that the test executable requires external file access to run if it is built with the latest (DEVELOPMENT-SNAPSHOT-2024-03-22-a-wasm) toolchain.
main-snapshot-2024-03-13 & DEVELOPMENT-SNAPSHOT-2024-03-20-a-wasm
main-snapshot-2024-03-20 & DEVELOPMENT-SNAPSHOT-2024-03-22-a-wasm
Environment