Skip to content

test(harness): wind down a throwaway vault - #261

Open
hpmaxi wants to merge 3 commits into
feat/vault-healthfrom
test/harness-wind-down
Open

hpmaxi wants to merge 3 commits into
feat/vault-healthfrom
test/harness-wind-down

Conversation

@hpmaxi

@hpmaxi hpmaxi commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

Summary

The harness never ran a wind-down, so the generated bindings never met the deployed Wasm on that path. This PR adds a wind-down run on a throwaway vault on the local network. It deploys a full vault set built from a short_wind_down Wasm, which drops the seven-day minimum and is never deployed elsewhere, takes it through a deposit, a redemption request, a wind-down and a claim, and checks that every function in the vault's spec is called through the generated client at least once.

Changes

  • deploy.ts is split into reusable functions and exposes deployThrowaway, which wires a full vault set from any vault Wasm
  • clients.ts exposes connectTo, so a test can connect to a deployment that was never written to disk
  • A new wind-down.test.ts suite runs the wind-down scenario on the local network and checks every vault function is exercised
  • docs/TESTING.md and README.md describe the new suite and the short_wind_down build it needs

Deviations

  • The task asked for the CI step to be saved rather than pushed. It's saved as .superpowers/sdd/2026-10-14-00-index/deferred/0004-ci-run-a-wind-down-on-a-throwaway-vault.patch for the controller to apply, so "Runs in CI after the guards" is unchecked below until that lands.

Acceptance criteria

  • Refuses to run on any network but local
  • Deposit, claim, redeem request, wind-down proposal and activation, a round and a claim all succeed
  • Every function in the vault's spec is called at least once
  • Runs in CI after the guards

Test plan

Automated tests

  1. Not yet: the CI step that runs this suite is deferred (see Deviations). The manual steps below are the current verification.

Manual verification

  1. On a local quickstart network, after stellar contract build, CARGO_TARGET_DIR=target/short-wind-down stellar contract build --package async-vault --features short_wind_down and npm run build:clients: run HARNESS_NETWORK=local npm run deploy -w scripts/harness then npm run test:wind-down -w scripts/harness. All 6 tests in "a wind-down on a throwaway vault" pass.
  2. Against that same fresh deploy, npm run test:happy-path -w scripts/harness (24 tests) and npm run test:guards -w scripts/harness (46 tests) still pass, confirming the deploy.ts refactor didn't change its behavior.

Breaking changes

None.

Checklist

  • Self-reviewed my own diff
  • Tests added or updated
  • Docs updated (if applicable)
  • No unrelated changes bundled in

Screenshots

None.

@vercel

vercel Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
strata-vault-kit-app Ready Ready Preview Oct 19, 2026 5:32pm UTC

Request Review

@hpmaxi
hpmaxi marked this pull request as ready for review October 17, 2026 16:46

This branch was successfully deployed

1 active deployment
Preview — 35867109 Deployed Oct 19, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant