mirror of
https://github.com/extism/extism.git
synced 2026-04-23 03:00:11 -04:00
feat: Improve usability of manifest types (#124)
- Adds some helper functions for creating a manifest, mostly helpful for the Rust SDK - Renames `ManifestWasm` to `Wasm` - Renames `ManifestMemory` to `MemoryOptions` - `ManifestWasm` and `ManifestMemory` have been marked as deprecated - Adds an alias from `MemoryOptions::max_pages` to `MemoryOptions::max` in serde specification Co-authored-by: Steve Manuel <steve@dylib.so>
This commit is contained in:
@@ -66,7 +66,7 @@ class TestExtism(unittest.TestCase):
|
||||
def _manifest(self):
|
||||
wasm = self._count_vowels_wasm()
|
||||
hash = hashlib.sha256(wasm).hexdigest()
|
||||
return {"wasm": [{"data": wasm, "hash": hash}], "memory": {"max": 5}}
|
||||
return {"wasm": [{"data": wasm, "hash": hash}], "memory": {"max_pages": 5}}
|
||||
|
||||
def _count_vowels_wasm(self):
|
||||
path = join(dirname(__file__), "code.wasm")
|
||||
|
||||
Reference in New Issue
Block a user