Sith/.github/workflows/ci.yml

47 lines
1.2 KiB
YAML
Raw Normal View History

2023-05-10 09:56:33 +00:00
name: Sith 3 CI
on:
push:
2023-11-05 22:42:52 +00:00
branches: [master, taiste, features/**]
2023-05-10 09:56:33 +00:00
pull_request:
branches: [master, taiste]
workflow_dispatch:
2023-05-10 09:56:33 +00:00
jobs:
black:
name: Black format
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
- name: Setup Project
uses: ./.github/actions/setup_project
- run: poetry run black --check .
tests:
name: Run tests and generate coverage report
runs-on: ubuntu-latest
2023-11-05 22:42:52 +00:00
container:
image: docker.elastic.co/elasticsearch/elasticsearch:7.17.14
env:
discovery.type: single-node
ports:
- 9200
2023-05-10 09:56:33 +00:00
steps:
- name: Check out repository
uses: actions/checkout@v3
- uses: ./.github/actions/setup_project
- uses: ./.github/actions/setup_xapian
- uses: ./.github/actions/compile_messages
- name: Run tests
run: poetry run coverage run ./manage.py test
- name: Generate coverage report
run: |
poetry run coverage report
poetry run coverage html
- name: Archive code coverage results
uses: actions/upload-artifact@v3
with:
name: coverage-report
path: coverage_report