1
我試圖使用xUnit插件將我的PHPUnit測試集成到Hudson中。一個全成之後建立與螞蟻在哈德森,控制檯輸出顯示:Hudson CI和PHPUnit:沒有任何測試報告包含任何結果
記錄測試結果
無的測試報告包含的任何結果
我使用junit.xml測試輸出PHPUnit的--log-的JUnit看起來如下:
<testsuites>
<testsuite name="Unit Tests" tests="1" assertions="1" failures="0" errors="0" time="0.005112">
<testsuite name="DbTest" file="src/tests/unit/DbTest.php" tests="1" assertions="1" failures="0" errors="0" time="0.005112">
<testcase name="testConnection" class="DbTest" file="src/tests/unit/DbTest.php" line="4" assertions="1" time="0.005112"/>
</testsuite>
</testsuite>
</testsuites>
任何幫助理解
編輯: 我剛創建包含測試junit.xml:
<testsuites>
<testsuite name="DbTest" file="src/tests/unit/DbTest.php" tests="1" assertions="1" failures="0" errors="0" time="0.005112">
<testcase name="testConnection" class="DbTest" file="src/tests/unit/DbTest.php" line="4" assertions="1" time="0.005112"/>
</testsuite>
</testsuites>
有了這個,構建成功了。問題似乎是嵌套標籤。任何想法如何防止PHPUnit創建這些嵌套標籤?
感謝您分享您的解決方案! +1 – edorian 2011-01-10 15:51:09