Skip to content

Add unit tests for sell revert when creator has zero total supply #370

@Chucks1093

Description

@Chucks1093

Summary
Attempting to sell keys when the creator has zero total supply is an impossible state, but the error handling for this edge is not explicitly tested. A unit test confirms the contract reverts with the expected error rather than producing an arithmetic panic.

Scope

  • add a unit test that calls the sell function against a creator with zero total supply
  • assert the call reverts with the expected error variant
  • assert no state changes occur as a result of the failed call

Acceptance Criteria

  • a sell against a zero-supply creator reverts with the correct error
  • no state mutation occurs from the failed call
  • the test is distinct from the insufficient balance sell revert test

Contributor coordination: if you pick this up, reach out in Telegram for updates or clarification: https://t.me/accesslayerorg

Metadata

Metadata

Assignees

No one assigned

    Labels

    Stellar WaveIssues in the Stellar wave program

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions