无法使用 genhtml 合并覆盖率数据
我正在使用 genhtml (在 Windows 中的 cygwin 下)从 2 个覆盖率数据文件生成单元测试覆盖率报告。它们都是来自同一单元测试源文件的覆盖率数据。
但是,当我输入以下命令时:
perl genhtml /home/administrator/coverage1.dat /home/administrator/coverage2.dat
我得到以下输出和问题:
Reading data file /home/administrator/coverage1.dat
Reading data file /home/administrator/coverage2.dat
genhtml: Can't use an undefined value as a HASH reference at genhtml line 1506.
并且它无法生成任何内容。
我研究了这些文件,发现原因之一可能是覆盖数据中重复的标头和文件。
这是一个已知问题,或者有人知道解决它的方法,还是我走错了路?
谢谢。
I'm using genhtml (in Windows under cygwin) to generate a unit test coverage report from 2 coverage data files. They are all coverage data from the same unit test source file.
However, when I entered the following command:
perl genhtml /home/administrator/coverage1.dat /home/administrator/coverage2.dat
I got the following output and problem:
Reading data file /home/administrator/coverage1.dat
Reading data file /home/administrator/coverage2.dat
genhtml: Can't use an undefined value as a HASH reference at genhtml line 1506.
And it failed to generate anything.
I played around with the files, and discovered that one reason might be because of the repeating headers and files in the coverage data.
Is this a known issue, or does anyone know a way to get around it, or am I on the wrong track?
Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我已经从sourceforge下载了最新的lcov和genhtml。它解决了问题。
谢谢。
I have downloaded the latest lcov and genhtml from sourceforge. It fixed the problem.
Thanks.
该消息是由于尝试取消引用未定义的值(就好像它是哈希引用一样)而导致的致命错误。
genhtml 中存在错误或您的数据文件已损坏。
您是否尝试过在 lcov 邮件列表上询问?
The message is a fatal error caused by trying to dereference an undefined value as if it were a hash reference.
There is either a bug in genhtml or your data files are corrupt.
Have you tried asking on the lcov mailing list?