Skip to content

feat: implement risk-pool and governance-dao contracts with full test suites (v2)#1

Merged
nonsobethel0-dev merged 38 commits into
mainfrom
feat/contracts-v2
Jun 14, 2026
Merged

feat: implement risk-pool and governance-dao contracts with full test suites (v2)#1
nonsobethel0-dev merged 38 commits into
mainfrom
feat/contracts-v2

Conversation

@nonsobethel0-dev

Copy link
Copy Markdown
Contributor

Summary

  • Risk Pool (contracts/risk-pool): Full LP deposit/withdraw system with proportional share minting, 80/10/10 premium routing to LPs/treasury/backstop, yield claim, capital locking per policy, pause/resume controls, and 25+ unit tests across 3 test files
  • Governance DAO (contracts/governance-dao): Token-weighted proposal lifecycle (create → vote → finalize → execute/cancel) with configurable quorum and majority thresholds, 15+ unit tests
  • Oracle Verifier enhancements: verify_trigger_fresh with staleness check, batch_submit_data, OracleHealth type; 10 new tests
  • Policy Engine enhancements: emergency_pause / emergency_resume, ProductStats type, is_paused query; 8 new tests
  • Claims Processor enhancements: batch_auto_process for settling multiple pending claims in one call; integration tests with real cross-contract execution
  • CI/CD: GitHub Actions workflow for build + test + clippy + WASM size report; release workflow for tagged versions
  • Scripts: deploy_mainnet.sh (dual-confirmation gate), create_products.sh, register_oracle.sh, submit_oracle_data.sh, check_balances.sh
  • Docs: ARCHITECTURE.md, SECURITY.md, CONTRIBUTING.md, docs/economics.md, docs/oracle-key-format.md, docs/deployment-checklist.md

This branch adds 35 new commits on top of the v1 baseline, bringing the total to 40 professional commits across all 5 contracts.

Test plan

  • make test — all unit and integration tests pass
  • make lint — zero clippy warnings
  • make build — all 5 WASM targets build successfully
  • make wasm-sizes — verify binary sizes are within reasonable bounds
  • Testnet smoke test via ./scripts/deploy_testnet.sh

@nonsobethel0-dev nonsobethel0-dev merged commit d183c64 into main Jun 14, 2026
2 of 4 checks passed
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