Skip to content

Add supply-cap zero-vs-max-i128 differential test locking boundary semantics #814

Description

@thlpkee20-wq

Description

supply_cap == 0 means disabled, supply_cap == i128::MAX means unbounded-but-enabled. Lock these semantics with a differential test asserting distinct code paths and event streams.

Requirements and context

  • Must be secure, tested, and documented
  • Should be efficient and easy to review
  • Relevant code: src/test_compute_share_invariants.rs
  • Test must run both configurations on identical inputs

Suggested execution

  • Fork the repo and create a branch
  • git checkout -b test/supply-cap-boundaries
  • Implement changes
    • Two fixtures: cap=0 and cap=i128::MAX
    • Run identical issuance sequences
    • Assert expected event and state differences
  • Validate security and correctness assumptions

Test and commit

  • Run tests
    • cargo test --all
  • Cover edge cases
    • Total issuance near i128::MAX
  • Include test output and security notes

Example commit message

test: differential test for supply-cap boundaries

Guidelines

  • Minimum 95 percent test coverage
  • Clear documentation
  • Timeframe: 96 hours

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions