Set up your GitHub Actions workflow with Probitas, a scenario-based testing framework.
The simplest setup installs the latest stable Probitas version:
- uses: probitas-test/setup-probitas@v2name: Test
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: probitas-test/setup-probitas@v2
- name: Run Probitas tests
run: probitas run| Input | Description | Default |
|---|---|---|
probitas-version |
The Probitas version to install (2.0.0 or later), or latest. |
latest |
cache |
Cache the DuckDB native binding that Probitas downloads on first use. | true |
| Output | Description |
|---|---|
probitas-version |
The Probitas version that was installed. |
Probitas 1.x ran on Deno and is installed by setup-probitas@v1, which keeps
working unchanged. @v2 installs Probitas 2 and later only, and fails with a
clear message when asked for a 1.x version.
- uses: probitas-test/setup-probitas@v1
with:
probitas-version: "1.0.0"- uses: probitas-test/setup-probitas@v2
with:
probitas-version: "2.0.0"Test across multiple Probitas versions:
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
probitas-version: ["latest", "2.0.0"]
steps:
- uses: actions/checkout@v4
- uses: probitas-test/setup-probitas@v2
with:
probitas-version: ${{ matrix.probitas-version }}
- run: probitas run- uses: probitas-test/setup-probitas@v2
- name: Run integration tests
run: probitas run -s tag:integration
- name: Run with custom reporter
run: probitas run --reporter json > results.jsonjobs:
test:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: probitas-test/setup-probitas@v2
- run: probitas runThis action performs the following steps:
- Resolve the version:
latestbecomes the newest Probitas GitHub Release - Install the binary: Downloads the platform's archive from the Probitas GitHub Release and verifies it against the release's
SHA256SUMS(on macOS and Linux through that release'sinstall.sh), then adds it to the PATH. No runtime is needed. - Cache DuckDB: Optionally caches the DuckDB native binding that Probitas downloads the first time a scenario uses DuckDB
- Verify Installation: Confirms Probitas is correctly installed and available in the PATH
This action follows semantic versioning. When a new version is released (e.g., v2.0.0), the following tags are automatically updated:
v2- Points to the latestv2.x.xreleasev2.0- Points to the latestv2.0.xrelease
# Recommended: Use major version for automatic updates
- uses: probitas-test/setup-probitas@v2
# Alternative: Pin to major.minor for more control
- uses: probitas-test/setup-probitas@v2.0
# Alternative: Pin to exact version for maximum stability
- uses: probitas-test/setup-probitas@v2.0.0Using @v2 ensures you automatically receive bug fixes and new features within the v2 major version, while avoiding breaking changes.
- Probitas - The Probitas framework and CLI
See LICENSE file for details.