我使用Hudson作为CI服务器来构建几个不同的.net 3.5项目。实际构建的东西效果很好。Hudson的工作与加利奥测试报告“没有测试”
不过,我运行使用Gallio.Echo作为构建的一部分MbUnit的V2测试,而测试似乎运行正常,哈德森称,没有测试运行。
我有以下生成步骤之后的 “建设使用的MSBuild一个Visual Studio项目或解决方案” 的步骤:
类型:执行Windows批处理命令 命令:
“C:\ Program Files文件\ Gallio \ bin \ Gallio.Echo.exe“TestLibrary \ bin \ Release \ TestLibrary.dll/rt:Xml/rnf:mbunit-result/rd :. 退出0
当构建运行,这给在控制台日志输出如下:
Gallio Echo - Version 3.1 build 313
Get the latest version at http://www.gallio.org/
Start time: 09:06
Initializing the runtime and loading plugins.
Verifying test files.
Initializing the test runner.
Running the tests.
[ignored] Test TestLibrary/ConfigTests/LoadAndSaveTest
Generating reports.
Disposing the test runner.
Stop time: 09:07 (Total execution time: 10,210 seconds)
64 run, 64 passed, 0 failed, 0 inconclusive, 1 skipped (1 ignored)
所以在我心中毫无疑问的是,实际测试运行 - 和MbUnit的-结果。 XML文件是在正确的地方,看起来不错。
我也配置了项目“发布加利奥测试结果报告”,只是指定的“检测报告个XML”值“MbUnit的,为result.xml”。
为了解决这个问题,我配置了Gallio插件(通过作业的config.xml文件),使jUnit文件(即Gallio插件从MbUnit测试结果创建的)保留在原地,然后我拿了一个查看junitResult.xml文件 - 奇怪的是每个套件的每个“cases”元素都是空的。即一个套件可以看起来像这样:
<suite>
<file>C:\Documents and Settings\Administrator\.hudson\jobs\TestProject\workspace\temporary-junit-reports\TEST-TestLibrary.Encryption_Tests.xml</file>
<name>TestLibrary.Encryption_Tests</name>
<duration>0.0</duration>
<cases/>
</suite>
据我所知,该部分是单个单元测试应该驻留的地方。此外,持续时间不应该是0.0。
正如你在上面看到的,我的Gallio版本是3.1版本313.这可能是由于这个Gallio版本的报告格式的改变(只是一个猜测,我不知道任何这样的改变)?
我哈德森v1.323运行,同时公堂插件v0.52。任何有关如何让哈德森看到测试结果的见解将不胜感激!
嗨菲利普, 这解决了我的问题,因为我也在谷歌代码链接(或试图)报告。非常感谢,无论是通用插件还是此修补程序! – 2009-11-04 08:09:04