notests --cover-html 不生成 html 文档

发布于 2024-09-08 23:39:34 字数 187 浏览 2 评论 0原文

我已经安装了 python 2.6 的鼻子,它工作正常,但我尝试使用 --cover-html 选项生成 html 报告。我从命令行输入了以下命令:

nosetests --cover-html

它运行了测试,但没有生成 html。

我错过了什么吗?

I have installed nose for python 2.6 and it works fine but I was trying use the --cover-html option to generate a html report. I typed the following command from the command line:

nosetests --cover-html

It ran the tests but did not generate the html.

Am I missing something ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

不打扰别人 2024-09-15 23:39:34

这是旧消息,但选项的顺序很重要:

nosetests --with-coverage --cover-erase --cover-html-dir=C:/temp/res --cover-html test.py

It's old news but the order of the options is important:

nosetests --with-coverage --cover-erase --cover-html-dir=C:/temp/res --cover-html test.py
可可 2024-09-15 23:39:34

您还需要 --with-coverage 选项来首先启用覆盖率插件。

You also need the --with-coverage option to enable the coverage plugin in the first place.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文