1
0
Fork 0
mirror of https://code.forgejo.org/actions/setup-forgejo synced 2024-09-19 01:46:16 +00:00

document variable controlled debug loop

This commit is contained in:
Earl Warren 2023-10-07 22:07:36 +02:00
parent 0fc67c08f7
commit 44400632c5
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00
2 changed files with 19 additions and 4 deletions

View file

@ -9,10 +9,10 @@ jobs:
- version: "1.21.0-2-rc0"
image: codeberg.org/forgejo-experimental/forgejo
# keep "cron" last otherwise it will linger and pollute the following runs
tests: "${{ vars.V121_TESTS || 'echo artifacts service checkout pull-request container expression local-action docker-action if if-fail cron' }}"
tests: "${{ vars.V1_21_TESTS || 'echo push-cancel artifacts service checkout pull-request container expression local-action docker-action if if-fail cron' }}"
- version: "1.20"
image: codeberg.org/forgejo/forgejo
tests: "${{ vars.V120_TESTS || 'echo checkout service container expression local-action docker-action if if-fail' }}"
tests: "${{ vars.V1_20_TESTS || 'echo checkout service container expression local-action docker-action if if-fail' }}"
steps:
- uses: actions/checkout@v3
- if: matrix.info.tests != 'none'

View file

@ -86,9 +86,13 @@ jobs:
## Hacking
* Update the README from the action file with https://github.com/npalm/action-docs `action-docs --update-readme`
### Documentation
To manually run and debug workflows from `testdata/example-*`, from
Update the README from the action file with https://github.com/npalm/action-docs `action-docs --update-readme`
### Local testing
To run and debug workflows from `testdata/example-*`, from
the root of the source directory, with docker and forgejo-curl.sh
installed, mimic what `.forgejo/workflows/integration.yml` does. There
may be some manual tweaking (such as creating temporary directories)
@ -105,3 +109,14 @@ because the tests run as root, but they do not need to run as root.
* `forgejo-test-helper.sh run_workflow testdata/example-$example http://root:admin1234@$(cat forgejo-ip):3000 root example-$example setup-forgejo $(cat forgejo-token)`
* `forgejo-runner.sh teardown`
* `forgejo.sh teardown`
### Remote testing
To reduce the runtime the following variables can be set to control
the number of cases run by the
[integration](.forgejo/workflows/integration.yml) tests. If set to
**none** they are not run at all for that version of Forgejo. If
it does not exist, all tests are run.
* `V1_21_TESTS`
* `V1_20_TESTS`