https://github.com/julia-vscode/testitem-workflow
https://github.com/julia-vscode/testitem-workflow
Last synced: 10 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/julia-vscode/testitem-workflow
- Owner: julia-vscode
- License: mit
- Created: 2024-07-13T18:53:35.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-10-06T02:19:49.000Z (about 1 year ago)
- Last Synced: 2025-01-08T00:34:40.427Z (11 months ago)
- Size: 41 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Test item reusable workflow
This repository provides a reusable GitHub Workflow that lints, runs test items, deploys documentation, checks for compatability updates and creates tags for Julia packages. It only works with packages that use the test item framework.
## PRERELEASE
This is very experimental prerelease software. It might break, not work etc. I will update this notice once it is ready for everyone to use.
## Getting started
Add the following file as `.github/workflows/juliaci.yml` to the repository of your package:
```yml
name: Julia CI
on:
push: {branches: [main,master]}
pull_request: {types: [opened,synchronize,reopened]}
issue_comment: {types: [created]}
schedule: [{cron: '0 0 * * *'}]
workflow_dispatch: {inputs: {feature: {type: choice, description: What to run, options: [CompatHelper,DocDeploy,LintAndTest,TagBot]}}}
jobs:
julia-ci:
uses: julia-vscode/testitem-workflow/.github/workflows/juliaci.yml@v1
permissions: write-all
secrets:
codecov_token: ${{ secrets.CODECOV_TOKEN }}
```
## Configuration
The `juliaci.yml` workflow accepts a number of configuration options that control on what Julia versions tests will be run. The following options are supported:
- `include-release-versions` (`true` or `false`, default `true`): run tests on the latest stable Julia version.
- `include-lts-versions` (`true` or `false`, default `true`): run tests on the latest long-term support Julia version.
- `include-all-compatible-minor-versions` (`true` or `false`, default `false`): run tests on all Julia minor versions that are compatible with the `[compat]` section in the package's `Project.toml`.
- `include-smallest-compatible-minor-versions` (`true` or `false`, default `true`): run tests on the smallest Julia minor versions that is compatible with the `[compat]` section in the package's `Project.toml`.
- `include-rc-versions` (`true` or `false`, default `false`): run tests on the latest release candidate Julia version.
- `include-beta-versions` (`true` or `false`, default `false`): run tests on the latest beta Julia version.
- `include-alpha-versions` (`true` or `false`, default `false`): run tests on the latest alpha Julia version.
- `include-nightly-versions` (`true` or `false`, default `false`): run tests on the latest nightly Julia version.
- `include-windows-x64` (`true` or `false`, default `true`): run tests on Windows x64.
- `include-windows-x86` (`true` or `false`, default `true`): run tests on Windows x86.
- `include-linux-x64` (`true` or `false`, default `true`): run tests on Linux x64.
- `include-linux-x86` (`true` or `false`, default `true`): run tests on Linux x86.
- `include-macos-x64` (`true` or `false`, default `true`): run tests on MacOS x64.
- `include-macos-aarch64` (`true` or `false`, default `true`): run tests on MacOS aarch64.
- `env` (JSON string): By passing a JSON string one can set environment variables for the Julia process that executes test items. For example `env: '{"FOO": "BAR"}'` would set an environment variable named `FOO` to the value `BAR`.
- `github_job_prep_script`: Path to a Julia file that is run once on each GitHub worker before tests are executed.
In the following example tests are run on release candidate versions if they are available:
```yml
name: Julia CI
on:
push: {branches: [main,master]}
pull_request: {types: [opened,synchronize,reopened]}
issue_comment: {types: [created]}
schedule: [{cron: '0 0 * * *'}]
workflow_dispatch: {inputs: {feature: {type: choice, description: What to run, options: [CompatHelper,DocDeploy,LintAndTest,TagBot]}}}
jobs:
julia-ci:
uses: julia-vscode/testitem-workflow/.github/workflows/juliaci.yml@v1
with:
include-rc-versions: true
permissions: write-all
secrets:
codecov_token: ${{ secrets.CODECOV_TOKEN }}
```