wasmer_integration_tests_cli/
fixtures.rs1use std::path::{Path, PathBuf};
4
5use crate::{asset_path, c_asset_path};
6
7pub fn resources() -> PathBuf {
8 Path::new(env!("CARGO_MANIFEST_DIR")).join("resources")
9}
10
11pub fn packages() -> PathBuf {
12 Path::new(env!("CARGO_MANIFEST_DIR"))
13 .join("tests")
14 .join("packages")
15}
16
17pub fn php() -> (PathBuf, PathBuf, PathBuf) {
18 let root = Path::new(env!("CARGO_MANIFEST_DIR"));
19 let resources = resources().join("php");
20 (
21 root.join("tests").join("wasm").join("php.wasm"),
22 resources.clone(),
23 resources.join("db"),
24 )
25}
26
27pub fn python() -> PathBuf {
29 c_asset_path().join("python--python@3.13.5.webc")
30}
31
32pub fn bash() -> PathBuf {
34 Path::new(env!("CARGO_MANIFEST_DIR"))
35 .join("tests")
36 .join("webc")
37 .join("bash-1.0.16-f097441a-a80b-4e0d-87d7-684918ef4bb6.webc")
38}
39
40pub fn wabt() -> PathBuf {
43 c_asset_path().join("wabt-1.0.37.wasmer")
44}
45
46pub fn qjs() -> PathBuf {
48 c_asset_path().join("qjs.wasm")
49}
50
51pub fn qjs_wasmer_toml() -> PathBuf {
53 c_asset_path().join("qjs-wasmer.toml")
54}
55
56pub fn fib() -> PathBuf {
58 asset_path().join("fib.wat")
59}
60
61pub fn wat_no_start() -> PathBuf {
63 asset_path().join("no_start.wat")
64}