mirror of
https://github.com/fluencelabs/wasmer
synced 2025-04-25 10:22:19 +00:00
Improved exported memory tests
This commit is contained in:
parent
2c6fbcba1f
commit
70a767e204
3
Cargo.lock
generated
3
Cargo.lock
generated
@ -589,6 +589,9 @@ dependencies = [
|
|||||||
name = "indexmap"
|
name = "indexmap"
|
||||||
version = "1.0.2"
|
version = "1.0.2"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
dependencies = [
|
||||||
|
"serde 1.0.98 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "inkwell"
|
name = "inkwell"
|
||||||
|
@ -42,8 +42,9 @@ int main()
|
|||||||
assert(export_length == 5);
|
assert(export_length == 5);
|
||||||
|
|
||||||
// Get the `memory` export.
|
// Get the `memory` export.
|
||||||
wasmer_export_t *export = wasmer_exports_get(exports, 1);
|
wasmer_export_t *export = wasmer_exports_get(exports, 0);
|
||||||
wasmer_import_export_kind kind = wasmer_export_kind(export);
|
wasmer_import_export_kind kind = wasmer_export_kind(export);
|
||||||
|
printf("Wasmer import export kind: %d (Memory is %d)\n", kind, WASM_MEMORY);
|
||||||
assert(kind == WASM_MEMORY);
|
assert(kind == WASM_MEMORY);
|
||||||
|
|
||||||
wasmer_byte_array export_name = wasmer_export_name(export);
|
wasmer_byte_array export_name = wasmer_export_name(export);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user