Tag: cruisecontrol


Finally, I embeded pbunit’s test result into CruiseControl.net’s dashboard. I worked very hard to make this happen. Things I have done includes:

  • Changed PBUnit to generate xml report. (Using datawindow xml template, and xsl-stylesheet)
  • Changed PBUnit to accept command line to pass pb target file.
  • Changed PBUnit to loop through all the pbls and components to do automated test.
  • Fixed a bug in PBUnit of lib path containing space.
  • Created a xsl for PBUnit’s test result.

After merging PBUnit’s test result into cc.net output, I can see my work appear on web now.


TODO list:

  • If a testcase class loading failed, application looks like hung there, stop button won’t change back to ‘Run’. Some exception check has to be done there.
  • Application should keep the recent target file info to next time auto-loading, just like NUnit.
  • Main Window should changed to tree-view style, like NUnit.
  • Capable to test a single method in testCase.
  • xml generated by datawindow still has some bug, the group header column can’t use expression. Which mean the element attributes in group header can use sum, or min function, so the total time and test-suite success and execute are all hard-coded to True now. This bug forced me had to change my pbunit-test.xsl file which was copied from Nuint-test.xsl. In line 103:

    <xsl:apply-templates select=”.//test-suite[@success=’False’][results/test-case]” >

    <xsl:apply-templates select=”.//test-suite[results/test-case/@success=’False’]” >

Also, unittests.xsl needs to be modified like this:


<xsl:variable name=”nunit2.time” select=”sum($nunit2.result.list/test-suite[position()=1]/@time)”/>
<xsl:variable name=”nunit2.failure.list” select=”$nunit2.case.list/failure”/>

<xsl:variable name=”nunit2.time” select=”sum($nunit2.result.list/test-suite/results/test-case/@time)”/>

<xsl:variable name=”nunit2.failure.list” select=”$nunit2.case.list[@success=’False’]”/>

line 73:

<xsl:call-template name=”nunit2testdetail”>
<xsl:with-param name=”detailnodes” select=”//test-suite/results/test-case[@success=’False’]”/>   (used be ../failure)

I really need somebody to help me to improve this tool, so I create a open-source project on SourceForge. But SF refused me to name it PBUnit, then PowerUnit came to my head.
SourceForge supports both CVS and SVN, neither is easy for Powerbuilder development, unless you can find a SCC proxy for CVS, it seems PuskOK from Russia is the only option by now.