Skip to content

ci: Let other repositories test generated models before merging - #12

Merged
howaskew merged 1 commit into
mainfrom
ci/testable-build-v2
Oct 21, 2026
Merged

howaskew merged 1 commit into
mainfrom
ci/testable-build-v2

Conversation

@howaskew

Copy link
Copy Markdown
Contributor

Allow the Update Data Model workflow to be called from other repositories with a models-lib or data-models ref. When called this way it generates the TypeScript models, builds and tests them, and does not create a pull request. models-lib pull requests can then check that the generated TypeScript compiles and passes the example tests.

Replaces #7, which predates the GitHub App token change: it used an expression in a reusable workflow uses: (not allowed), and checked out the calling repository instead of models-ts when called from elsewhere. This version runs the tests in the same job, so no nested workflow or artifact is needed.

Also:

  • name the models-ts repository in its checkout
  • run the models-ts tests (tsc and mocha) before creating a pull request
  • Node 18.17.1, actions/checkout v4, actions/setup-node v4
  • peter-evans/create-pull-request v7 (v4 fails after updating an existing pull request: "Cannot read properties of undefined")

Allow the Update Data Model workflow to be called from other
repositories with a models-lib or data-models ref. When called this way
it generates the TypeScript models, builds and tests them, and does not
create a pull request. models-lib pull requests can then check that the
generated TypeScript compiles and passes the example tests.

Replaces #7, which predates the GitHub App token change: it used an
expression in a reusable workflow `uses:` (not allowed), and checked out
the calling repository instead of models-ts when called from elsewhere.
This version runs the tests in the same job, so no nested workflow or
artifact is needed.

Also:
- name the models-ts repository in its checkout
- run the models-ts tests (tsc and mocha) before creating a pull request
- Node 18.17.1, actions/checkout v4, actions/setup-node v4
- peter-evans/create-pull-request v7 (v4 fails after updating an
  existing pull request: "Cannot read properties of undefined")

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@howaskew
howaskew requested a review from hkir-dev October 21, 2026 12:29
@howaskew
howaskew merged commit f211cc1 into main Oct 21, 2026
3 checks passed
@howaskew
howaskew deleted the ci/testable-build-v2 branch October 21, 2026 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants