Skip to content

Add comprehensive end-to-end pipeline test #49

@PAMulligan

Description

@PAMulligan

Description

Create an end-to-end test that runs the full `/build-from-schema` pipeline against a sample OpenAPI spec and verifies the output at every phase.

Why

The pipeline is Nerva's core value proposition. Without an E2E test, there's no automated verification that the 10-phase pipeline produces a working API. This is the most critical test the project can have — it validates that all skills, agents, and scripts work together correctly.

Acceptance Criteria

  • Create a sample OpenAPI spec (`tests/fixtures/petstore.yaml`) with:
    • 2-3 resources (pets, owners)
    • CRUD operations
    • Auth requirements
    • Relations between resources
  • Create a test harness that runs the pipeline phases in sequence
  • Verify after each phase:
    • Phase 0: `build-spec.json` exists and is valid JSON
    • Phase 1: Drizzle schema files exist with correct tables
    • Phase 2: Integration test files exist and fail (RED)
    • Phase 3: Route handler files exist
    • Phase 5: Tests pass (GREEN)
    • Phase 8: Deployment config files exist
    • Phase 9: Build report exists
  • Run as a separate CI workflow (not on every push — resource intensive)
  • CI workflow has a manual trigger for on-demand testing
  • Document how to run the E2E test locally

Notes

This test requires a running PostgreSQL instance. Use Docker Compose or `testcontainers` in CI.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions