Add custom filter to parse default value from dict to json #1790
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: On pull request | |
on: [pull_request] # set to this value when pushing in prod | |
#on: [push] # set this one for dev the ci/cd | |
env: | |
DJANGO_SETTINGS_MODULE: Squest.settings | |
jobs: | |
unit-tests: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ['3.12'] | |
poetry-version: ['1.8.0'] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install system dependencies | |
run: | | |
sudo apt update | |
sudo apt install -y libuv1-dev | |
sudo apt install -y default-libmysqlclient-dev gcc npm libldap2-dev libsasl2-dev graphviz libsqlite3-dev | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install poetry | |
uses: abatilo/actions-poetry@v2.0.0 | |
with: | |
poetry-version: ${{ matrix.poetry-version }} | |
- name: Install dependencies | |
run: | | |
poetry install | |
- name: Run Tests | |
run: | | |
poetry run coverage run --source='.' manage.py test | |
- name: Run coverage report | |
run: | | |
poetry run coverage report | |
- name: Generate HTML report | |
run: | | |
poetry run coverage html | |
- name: Generate lcov report | |
run: | | |
poetry run coverage lcov | |
- name: 'Upload Artifact' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: htmlcov | |
path: htmlcov | |
- name: Coveralls | |
uses: coverallsapp/github-action@master | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
path-to-lcov: coverage.lcov |