Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想使用Ned Batchelder 的覆盖模块运行“nosetests --with-coverage” ,但将覆盖模块传递给 --timid 标志。有没有办法(例如设置环境变量)使用--timid 运行覆盖?
你有两个选择:
使用 .coveragerc 文件为 coverage.py 提供选项
不是在鼻子内运行覆盖,而是在覆盖内运行鼻子:
coverage run c:\python25\scripts\nosetests-script.py
(如果您不在 Windows 上,请对 Windows 语法感到抱歉)