bat-extras/.github/actions/test/action.yaml
Ethan P 90bb604d74
ci: Add GitHub Actions test workflow
This will eventually replace CircleCI.
2022-07-29 15:55:51 -07:00

34 lines
716 B
YAML

name: 'Test'
description: 'Tests bat-extras'
inputs:
strict:
description: 'Tests should be run under strict mode'
required: false
default: false
compiled:
description: 'Test scripts that have been built'
required: false
default: false
runs:
using: composite
steps:
- name: Run tests
shell: bash
run: |
args=()
if "${{ inputs.compiled }}"; then
args+=(--compiled)
fi
if "${{ inputs.strict }}"; then
args+=(--strict)
fi
cd "${{ github.workspace }}"
PATH="${{ runner.temp }}/bin:${PATH}"
bash "${{ github.workspace }}/test.sh" "${args[@]}" \
--verbose --snapshot:show