Skip to content

Test

Test #6

Workflow file for this run

name: Test
on:
pull_request:
push:
branches:
- main
workflow_dispatch:
inputs:
workers:
description: number of workers
type: string
default: '0'
jobs:
run-tests:
name: "Run tests"
runs-on: ubuntu-latest
env:
BUILDKITE_ANALYTICS_TOKEN: ${{ secrets.BUILDKITE_ANALYTICS_TOKEN }}
BUILDKITE_ANALYTICS_DEBUG_ENABLED: 'TRUE'
BUILDKITE_ANALYTICS_MESSAGE: 'Test run with ${{inputs.workers}} workers'
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Python
uses: actions/[email protected]
with:
python-version: '3.12'
- name: Install project
run: |
python3 -m pip install --user pipenv
python3 -m pipenv --python 3
python3 -m pipenv install
- name: Run tests
env:
WORKERS: ${{inputs.workers || '1'}}
run: python3 -m pipenv run pytest -n=${{env.WORKERS}} -v --capture=no