Coverage.py warning: No data was collected. (no-data-collected)

后端 未结 6 901
我在风中等你
我在风中等你 2020-12-15 16:40

I am trying to find the coverage using coverage module for a django project but gets

Coverage.py warning: No data was collected. (no-data-collected)
         


        
6条回答
  •  时光取名叫无心
    2020-12-15 16:57

    I encountered this error with tox:

    Coverage.py warning: No data was collected. (no-data-collected)
    

    My configuration performs an install of the module and tests that rather than the source code. However, test discovery was finding a module that I had named test_*.py in my app package, causing PYTHONPATH confusion and resulting in failure to collect coverage details. Renaming the module to not start with test_ resolved the issue.

提交回复
热议问题