1
0
Fork 0
mirror of https://code.forgejo.org/forgejo/runner.git synced 2025-09-30 19:22:09 +00:00
forgejo-runner/act/schema
2franix ea824bde1c
chore: test: exercise contexts in matrix when validating workflows (#1033)
After realizing my mistake on my proposed fixes in #1028, I figured I could at least propose another test covering the use of contexts in `jobs.<job-id>.strategy.matrix`.

The specification for available contexts is [here](https://docs.github.com/en/actions/reference/workflows-and-actions/contexts#context-availability):

| Workflow key | Context |
| -------------------- | ----------- |
| `jobs.<job_id>.strategy` | `github`, `needs`, `vars`, `inputs` |

In Forgejo, the `forge` and `forgejo` contexts are supported in addition to `github`.

The new test covers a matrix with [`include`](https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idstrategymatrixinclude), [`exclude`](https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#jobsjob_idstrategymatrixexclude) and custom properties. Both available and unavailable contexts are tested.

<!--start release-notes-assistant-->
<!--URL:https://code.forgejo.org/forgejo/runner-->
- other
  - [PR](https://code.forgejo.org/forgejo/runner/pulls/1033): <!--number 1033 --><!--line 0 --><!--description Y2hvcmU6IHRlc3Q6IGV4ZXJjaXNlIGNvbnRleHRzIGluIG1hdHJpeCB3aGVuIHZhbGlkYXRpbmcgd29ya2Zsb3dz-->chore: test: exercise contexts in matrix when validating workflows<!--description-->
<!--end release-notes-assistant-->

Co-authored-by: 2franix <code@c.defx.fr>
Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/1033
Reviewed-by: earl-warren <earl-warren@noreply.code.forgejo.org>
Co-authored-by: 2franix <2franix@noreply.code.forgejo.org>
Co-committed-by: 2franix <2franix@noreply.code.forgejo.org>
2025-09-28 07:15:51 +00:00
..
action_schema.json feat: the forgejo context is equivalent to the github context (#999) 2025-09-15 09:14:11 +00:00
schema.go fix: schema validation must accept aliases and merges (#1012) 2025-09-18 07:19:44 +00:00
schema_test.go chore: test: exercise contexts in matrix when validating workflows (#1033) 2025-09-28 07:15:51 +00:00
workflow_schema.json feat: the forgejo context is equivalent to the github context (#999) 2025-09-15 09:14:11 +00:00