aboutsummaryrefslogtreecommitdiff
path: root/test/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/main.c')
-rw-r--r--test/main.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/test/main.c b/test/main.c
new file mode 100644
index 0000000..d88552e
--- /dev/null
+++ b/test/main.c
@@ -0,0 +1,18 @@
+#include <wasmfs.h>
+#include <stddef.h>
+#include <stdio.h>
+#include <stdlib.h>
+
+int main(int argc, char *argv[])
+{
+ struct wasmfs *const w = wasmfs_load("example.wasm");
+
+ if (!w)
+ {
+ fprintf(stderr, "%s: wasmfs_load failed\n", __func__);
+ return EXIT_FAILURE;
+ }
+
+ wasmfs_unload(w);
+ return EXIT_SUCCESS;
+}