Skip to content

Closes #883 - #1288

Open
mansur-codes wants to merge 2 commits into
Epta-Node:mainfrom
mansur-codes:main
Open

Closes #883#1288
mansur-codes wants to merge 2 commits into
Epta-Node:mainfrom
mansur-codes:main

Conversation

@mansur-codes

Copy link
Copy Markdown
Contributor

Summary

Adds comprehensive unit, invariant, and fuzz test coverage for the credential/ZK subsystem (update_credential_root, verify_credential, get_credential_root). These three functions had zero tests despite being central to the platform's identity verification system. 322 tests pass, 387 across all integration suites.

Type of Change

  • Bug fix
  • New feature
  • Contract change (logic, storage, or API)
  • Documentation update
  • Refactor / chore

Testing Done

Added 15 unit tests in test.rs, 7 invariant tests in tests/invariants.rs, and 5 fuzz property tests in tests/fuzz_credential.rs. Coverage includes valid/invalid Merkle proofs, nullifier replay prevention, cross-user root isolation, depth-0 empty proof behavior, and nullifier non-consumption on failed verification. Also fixed 16 pre-existing tip tests that were failing due to missing set_profile calls for author addresses.

  • cargo test passes
  • New tests added for changed behaviour
  • Manually verified on Testnet (if applicable)
  • Database migration tested (if applicable)
  • TypeScript SDK tests passed (if applicable)

Checklist

  • Changes are focused — one concern per PR
  • If a contract function was added or changed, the README API table is updated
  • No unresolved merge conflicts
  • No secrets or private keys committed

Related Issue

Closes #883

@drips-wave

drips-wave Bot commented Aug 28, 2026

Copy link
Copy Markdown

@mansur-codes Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@vercel

vercel Bot commented Aug 28, 2026

Copy link
Copy Markdown

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

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
linkora-social-web Skipped Skipped Aug 29, 2026 5:59am

@devJaja

devJaja commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

@mansur-codes

Resolve conflicts

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.

[MEDIUM][Contract] Add comprehensive test coverage for credential/ZK subsystem

2 participants