简体   繁体   中英

How to get pytest-cov only if total coverage lower then 90%

So as I understood, pytest-cov has an option to fail if total coverage is lower than some %. But can I output hole tablet only in case if total cov is lower then 90% and if it is upper it won't show anything?

Example of command line code

pytest-cov doesn't have this option, but you don't have to use pytest-cov to produce the report. Use the plugin to run coverage, then in a separate command, produce the report: coverage report . You can conditionally run that separate command based on whatever condition you want.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM