28 lines
657 B
YAML
28 lines
657 B
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: shell
|
|
steps:
|
|
- name: Install dependencies
|
|
run: pip install -r requirements.txt
|
|
|
|
- name: Run tests
|
|
run: python -m pytest tests/ -v
|
|
|
|
- name: Create issue on failure
|
|
if: failure()
|
|
run: |
|
|
python scripts/create_failure_issue.py \
|
|
--sha "${{ github.sha }}" \
|
|
--branch "${{ github.ref_name }}" \
|
|
--run "${{ github.run_number }}" \
|
|
--message "${{ github.event.head_commit.message }}" \
|
|
--api-token "${{ secrets.document_analyzer }}"
|