Skip to content

Commit

Permalink
upd
Browse files Browse the repository at this point in the history
  • Loading branch information
Friskes committed Apr 29, 2024
1 parent ad30bd9 commit c316730
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 2 deletions.
15 changes: 13 additions & 2 deletions .github/workflows/publish-to-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,20 @@ jobs:
run: |
python -m mypy
- name: Run pytest
- name: Run pytest with coverage
run: |
python -m pytest
python -m pytest --cov
- name: Store the coverage data
uses: actions/upload-artifact@v4
with:
name: coverage-data
path: .coverage

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4.0.1
with:
token: ${{ secrets.CODECOV_TOKEN }}

build:
name: Build distribution 📦
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ trash
.pytest_cache
.ruff_cache
.mypy_cache
.coverage
17 changes: 17 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,17 @@ dev = [
"ruff==0.4.1",
"pytest>=7.0.1",
"mypy>=1.10.0",
"pytest-cov>=5.0.0",
# "covdefaults",
# "codecov-cli",
]
ci = [
"ruff==0.4.1",
"pytest>=7.0.1",
"mypy>=1.10.0",
"pytest-cov>=5.0.0",
# "covdefaults",
# "codecov-cli",
]


Expand Down Expand Up @@ -112,6 +118,17 @@ disallow_untyped_calls = false # [no-untyped-call]
warn_return_any = false # [no-any-return]


[tool.coverage.run]
concurrency = ["multiprocessing", "thread"]
omit = ["*/tests/*"]
parallel = true
# plugins = ["covdefaults"]
source = ["src.drf_spectacular_websocket"]

[tool.coverage.report]
fail_under = 50


# https://docs.astral.sh/ruff/settings/
# https://docs.astral.sh/ruff/configuration/#full-command-line-interface
# cmd: ruff format # Отформатирует все файлы в `.` текущем каталоге.
Expand Down

0 comments on commit c316730

Please sign in to comment.