Skip to content

Basic tests (unit & integration) for core flows #12

@RafaelJohn9

Description

@RafaelJohn9

Create unit tests for backend helpers and integration tests for the simulated token flow (tokenize -> transfer -> verify).

Description (deep):
Tests increase reliability. Unit-test the canonical JSON generator, hash function, and IPFS upload mock. Integration tests should run against Hedera testnet (or a mocked Hedera SDK) to assert token creation and transfers succeed and DB is updated accordingly. For hackathon scope, focus on deterministic unit tests and a small end-to-end integration test demonstrating token creation and a single transfer.

Acceptance checklist

  • Add unit tests for metadata generation and hashing
  • Add unit tests for IPFS upload (use mocked client)
  • Add an integration test that mints a token and transfers a small quantity to a dummy buyer (testnet or mocked)
  • Integrate tests into npm test or similar command

Metadata

Metadata

Assignees

No one assigned

    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