@@ -27,6 +27,7 @@ name = "vm"
2727[features ]
2828default = [" runtime" , " cli" , " cranelift-jit" ]
2929runtime = []
30+ http-client = [" dep:reqwest" , " dep:url" , " dep:tokio" , " dep:futures-util" ]
3031edge-abi = [
3132 " dep:edge_abi" ,
3233 " edge_abi/console" ,
@@ -60,6 +61,10 @@ cranelift-jit = { version = "0.129.1", optional = true }
6061cranelift-module = { version = " 0.129.1" , optional = true }
6162cranelift-native = { version = " 0.129.1" , optional = true }
6263pd-host-function = { path = " ./pd-host-function" , version = " 0.1.0" }
64+ reqwest = { version = " 0.12" , default-features = false , features = [" rustls-tls" , " stream" ], optional = true }
65+ url = { version = " 2" , optional = true }
66+ futures-util = { version = " 0.3" , optional = true }
67+ tokio = { version = " 1" , features = [" rt" , " net" , " time" ], optional = true }
6368edge_abi = { package = " pd-edge-abi" , version = " 0.1.1" , default-features = false , optional = true }
6469futures-channel = " 0.3"
6570paste = " 1"
@@ -85,5 +90,10 @@ name = "host_binding_generation_tests"
8590path = " tests/host_binding_generation_tests.rs"
8691required-features = [" cranelift-jit" ]
8792
93+ [[test ]]
94+ name = " http_host_tests"
95+ path = " tests/vm/http_host_tests.rs"
96+ required-features = [" http-client" ]
97+
8898[build-dependencies ]
8999syn = { version = " 2" , features = [" full" ] }
0 commit comments