Commit 661f0ae
committed
test: add sessions-canary fixture for host integration of act:sessions
Hand-rolled minimal component exporting both \`act:tools/tool-provider\`
and \`act:sessions/session-provider\`. Each session holds a \`u64\`
counter; tools \`read\` and \`increment\` operate on the counter
identified by \`std:session-id\` in call metadata.
This is a stand-in until act-sdk-rs grows session macros — at which
point we'd write a proper SDK-driven component. The canary lets us
implement and test session-provider host bindings against a real
.wasm artifact without depending on SDK work.
Layout:
- act-cli/tests/fixtures-src/sessions-canary/ — source crate (own
workspace, not part of act-cli's)
- act-cli/tests/fixtures/sessions-canary.wasm — packed binary tracked
in git for tests
Verified the existing host (basic ActWorld with tool-provider only)
loads the canary fine — extra exports (session-provider) are not a
mismatch error in wasmtime. \`act info --tools\` lists the tools, and
calling tools without std:session-id returns \`std:invalid-args\` as
expected; calling with an unknown session-id returns
\`std:session-not-found\`.1 parent 65d47f9 commit 661f0ae
11 files changed
Lines changed: 1014 additions & 0 deletions
File tree
- act-cli/tests
- fixtures-src
- sessions-canary
- src
- wit
- deps
- act-core
- act-sessions
- act-tools
- fixtures
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
0 commit comments