You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In a Python project, you can define a Poe action in your pyproject.toml to run test coverage using a tool like pytest with the pytest-cov plugin. Here’s an example of how you can configure it:
Explanation:
• pytest: The testing framework.
• --cov=your_package_name: Specifies the package or module to measure coverage for.
• --cov-report=term-missing: Displays a detailed report in the terminal, showing uncovered lines.
Running the Action
You can run this task by executing the following command in your terminal:
poe coverage
Output
This will run the tests and display a coverage report in the terminal, highlighting which lines of code were not covered by tests.
The text was updated successfully, but these errors were encountered:
What feature would you like to be added?
Add code coverage for CI, and
poe
action.Why is this needed?
Enforce unit tests coverage
Suggestion
In a Python project, you can define a Poe action in your pyproject.toml to run test coverage using a tool like pytest with the pytest-cov plugin. Here’s an example of how you can configure it:
pyproject.toml
Explanation:
• pytest: The testing framework.
• --cov=your_package_name: Specifies the package or module to measure coverage for.
• --cov-report=term-missing: Displays a detailed report in the terminal, showing uncovered lines.
Running the Action
You can run this task by executing the following command in your terminal:
Output
This will run the tests and display a coverage report in the terminal, highlighting which lines of code were not covered by tests.
The text was updated successfully, but these errors were encountered: