Overview
⚠️ Depends on: #34–#40 (GF-01 through GF-07) — cargo test is only meaningful once the contract tests written in those issues exist. The CI job should be updated when the first contract implementation is merged.
The CI pipeline has critical gaps that allow broken code to pass undetected. This issue hardens the pipeline so that every PR is fully validated before merge.
Problem
Reviewing .github/workflows/ci.yml reveals:
cargo test is not run — the contracts job only runs cargo build --target wasm32-unknown-unknown --release. A failing test will pass CI without any warning.
pnpm lint is not run — the app package.json defines a lint script (next lint) but the CI workflow only runs pnpm typecheck. Linting errors are never caught automatically.
cargo clippy is missing — no Rust lint step exists. Common mistakes (unused variables, needless borrows, etc.) are not flagged.
- SDK
tsc build not verified — the SDK CI job only runs pnpm typecheck (tsc --noEmit) but never runs pnpm build (tsc), so the dist/ output required by package.json's main and types fields is never verified to generate correctly.
- No testnet smoke test — after testnet deployment (GF-11), there is no automated check that the deployed contracts respond correctly.
Proposed Solution
Update .github/workflows/ci.yml:
1. Add cargo test to the contracts job
- name: Run contract tests
run: cargo test
Add this after the existing build step.
2. Add cargo clippy to the contracts job
- name: Clippy lint
run: cargo clippy -- -D warnings
-D warnings treats all warnings as errors, preventing gradual lint drift.
3. Add pnpm lint to the app job
- name: Lint
working-directory: app
run: pnpm lint
Add this after the existing pnpm typecheck step.
4. Add SDK build step
- name: Build SDK
working-directory: sdks/typescript
run: pnpm build
This verifies the dist/ output is generated without TypeScript errors.
5. Add testnet smoke-test job (runs after GF-11 deployment)
A separate job that:
- Reads contract addresses from
deployments/testnet.json
- Calls
VaultRouter.position(test_address, Flex) via the Soroban RPC
- Asserts a valid response (not a Soroban error)
- Fails the workflow if the RPC call errors
Acceptance Criteria
Overview
The CI pipeline has critical gaps that allow broken code to pass undetected. This issue hardens the pipeline so that every PR is fully validated before merge.
Problem
Reviewing
.github/workflows/ci.ymlreveals:cargo testis not run — the contracts job only runscargo build --target wasm32-unknown-unknown --release. A failing test will pass CI without any warning.pnpm lintis not run — the apppackage.jsondefines alintscript (next lint) but the CI workflow only runspnpm typecheck. Linting errors are never caught automatically.cargo clippyis missing — no Rust lint step exists. Common mistakes (unused variables, needless borrows, etc.) are not flagged.tscbuild not verified — the SDK CI job only runspnpm typecheck(tsc --noEmit) but never runspnpm build(tsc), so thedist/output required bypackage.json'smainandtypesfields is never verified to generate correctly.Proposed Solution
Update
.github/workflows/ci.yml:1. Add
cargo testto the contracts jobAdd this after the existing build step.
2. Add
cargo clippyto the contracts job-D warningstreats all warnings as errors, preventing gradual lint drift.3. Add
pnpm lintto the app jobAdd this after the existing
pnpm typecheckstep.4. Add SDK build step
This verifies the
dist/output is generated without TypeScript errors.5. Add testnet smoke-test job (runs after GF-11 deployment)
A separate job that:
deployments/testnet.jsonVaultRouter.position(test_address, Flex)via the Soroban RPCAcceptance Criteria
cargo testruns in CI and fails the workflow if any test failscargo clippy -- -D warningsruns in CI and fails on any warningpnpm lintruns in CI for the app and fails on lint errorspnpm buildruns in CI for the SDK and verifiesdist/is generatedworkflow_dispatchtrigger initially)