Skip to content

[Feature]: Add baseline API tests for core routes #3

@nikkogibler

Description

@nikkogibler

Area

API or backend

What problem are you trying to solve?

We currently have no baseline automated coverage around the core API routes, which makes regressions harder to catch when changing route logic, seed data, or response shapes.

Proposed solution

Add a small API test harness and start with a bounded slice of read-route coverage.

Suggested starting scope:

  • GET /api/healthz
  • GET /api/bots
  • GET /api/tools
  • GET /api/addons
  • GET /api/dashboard/summary

Acceptance criteria:

  • a test runner is added and documented
  • at least the listed routes have passing automated tests
  • tests can run locally without requiring manual server startup
  • README or contributing docs mention how to run the tests

Alternatives considered

  • Keep relying on manual smoke testing only.
    This is faster in the short term, but it does not protect against regressions as the route surface grows.

  • Add full end-to-end coverage for every endpoint immediately.
    This would be higher coverage, but it is too broad for a starter issue and would slow down implementation.

Scope and impact

  • establish a small test harness for the API server
  • cover a representative set of read endpoints first
  • make future backend changes safer

Relevant code:

  • artifacts/api-server/src/routes/health.ts
  • artifacts/api-server/src/routes/bots.ts
  • artifacts/api-server/src/routes/equipment.ts
  • artifacts/api-server/src/routes/dashboard.ts

Notes:

Keep scope tight. This issue is about a baseline test harness plus a first slice of route coverage, not full end-to-end coverage for every endpoint.

Pre-flight checks

  • I searched existing issues and did not find a duplicate.
  • I explained the problem, not just the desired feature.

Metadata

Metadata

Assignees

No one assigned

    Labels

    apiHTTP routes, contracts, request & response shapes, AI spec, and client-server integration concernsbackendServer logic, data, db access, validation, rate limiting, AI integrations, & app behavior behind APIgood first issueGood for newcomers

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions