三叶草没有拾取某些物体

发布于 2024-11-04 21:50:38 字数 212 浏览 0 评论 0原文

我注意到三叶草没有获取我所上的一门特定课程的结果。 它是一个域对象,有 3 个重载构造函数。

它在 Clover 报告中显示为 0% 覆盖率。 我什至编写了一个虚拟测试用例来测试所有构造函数、访问器方法等,但它仍然显示为具有 0% 覆盖率

同一包中的其他对象被 clover 完全拾取,

我需要做些什么来确保这一点物体被三叶草拾起?

谢谢 达米安

I noticed clover is not picking up results for 1 particular class that I have.
Its a domain object that has 3 overloaded constructors.

It shows up in the clover reports as having 0% coverage.
I even wrote a dummy test case to test all the constructors, accessor methods etc and it stilled showed up as having 0% coverage

Other objects in the same package are picked up perfectly ok by clover

is there anything I need to do to ensure that this object is picked up by clover?

Thanks
Damien

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

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

发布评论

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

评论(1

故事和酒 2024-11-11 21:50:38

确保相关类的编译单元没有 CLOVER:OFF 指令,并检查以确保 Clover 正在检测类文件。

几年前,我对 Clover 有过一些使用经验,我记得有一个问题,即覆盖率数据写入得不够快。 Atlassian 团队的建议是在单独的 JVM 中分叉每个测试,而不是对它们进行批处理。

例如,这可能只是 Clover 仪器中的一个错误。根据我的经验,团队的反应非常灵敏;可能值得检查他们的论坛。

Ensure that the compilation unit of the relevant class doesn't have a CLOVER:OFF directive, and check to make sure the classfile is being instrumented by Clover.

A couple of years ago, I had a small amount of experience with Clover, and I remember having a problem whereby the coverage data wasn't being written quickly enough. Recommendation from the Atlassian team was to fork each test in a separate JVM, rather than batch them.

It could simply be a bug in Clover's instrumentation, for example. In my experience the team is pretty responsive; might be worthwhile to check on their forums.

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