Skip to content

Generated App Tests: emit schema-driven contract integration tests #29

@snissn

Description

@snissn

Background
Generated apps need schema-specific contract behavior tests emitted alongside app code.

Scope

  • Emit contract integration tests in generated app output that cover, per collection:
    • create
    • list/get
    • update (if mutable fields exist)
    • delete (if enabled)
    • transfer (if enabled)
    • payment enforcement for paid creates (if configured)
  • Tests should run against local anvil and use generated ABI + manifest/deployment address.

Implementation details

  • Build schema-to-test-case mapper in generator layer.
  • Generate per-collection test fixtures with deterministic naming.
  • Include robust assertions for expected failures (e.g., unpaid create revert for payment collections).

Acceptance criteria

  • Generated tests pass for canonical job-board output.
  • Generated tests fail when expected behavior is broken (e.g., payment removed, missing function).
  • Docs in generated app explain local prerequisites (anvil) and how to run contract tests.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    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