Skip to content

Add Drizzle schema validation to CI workflow #57

@PAMulligan

Description

@PAMulligan

Description

Add a CI validation step that checks the example Drizzle schema in `setup-project.sh` for TypeScript correctness. Currently the embedded TypeScript code in the shell script is not type-checked.

Why

The schema template in `setup-project.sh` is TypeScript embedded in a heredoc — it's invisible to `tsc`. If a Drizzle API change breaks the template, users would discover the error only after running `setup-project.sh`. A CI check catches this during development.

Acceptance Criteria

  • Extract the TypeScript templates from `setup-project.sh` into a testable format
  • Add a CI step that type-checks the extracted templates against the current Drizzle version
  • This can be done by:
    • Creating a `tests/templates/` directory with the embedded TS extracted as files
    • Running `tsc --noEmit` against them
    • Or using a snapshot comparison approach
  • CI passes

Notes

This is a creative problem — the TypeScript is embedded in bash heredocs. One approach is to extract the templates to standalone `.ts` files in a test directory and type-check them separately.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions