Skip to content

Commit

Permalink
[chores] Fixed configuration to track websocket coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
pandafy authored and nemesifier committed Aug 12, 2024
1 parent 58c293a commit 73cd858
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
[tool.coverage.run]
source = ["openwisp_notifications"]
parallel = true
concurrency = ["multiprocessing"]
# To ensure correct coverage, we need to include both
# "multiprocessing" and "thread" in the concurrency list.
# This is because Django test suite incorrectly reports coverage
# when "multiprocessing" is omitted and the "--parallel" flag
# is used. Similarly, coverage for websocket consumers is
# incorrect when "thread" is omitted and pytest is used.
concurrency = ["multiprocessing", "thread"]
omit = [
"openwisp_notifications/__init__.py",
"*/tests/*",
Expand Down

0 comments on commit 73cd858

Please sign in to comment.