3 Replies Latest reply on Dec 3, 2008 2:48 PM by slawek t

    Seam TestNG tests and Hudson CI problem

    slawek t Novice

      Hi,


      I've created simple seam project with seam-gen tool, and wrote few tests based on SeamTest (TestNG). It's checked-in into SVN and taking by Hudson CI to perform tests and report it.
      Everything is ok, tests are performing, XML report is being produced but Hudson can't understand the content of XML report file correctly and claims that there are no test results in this file to be found.


      Do you have such problems and some solutions how to persuade Hudson to correctly understand XML report file?


        • 1. Re: Seam TestNG tests and Hudson CI problem
          slawek t Novice

          I understand that nobody faced this problem. I'm curious how it's been configured in jboss'es hudson building and testing seam-trunk because it's based on TestNG also. Does anybody know?

          • 2. Re: Seam TestNG tests and Hudson CI problem
            Stefano Travelli Newbie

            I use Hudson with a seam-gen project. Test reports are published with these settings:



            I checked Publish JUnit test result report and set


            <myproject>/test-report/**/*.xml
            



            in Text Report XML.


            This is the 'test' ant target. Can't remember if I manually changed something after seam-gen:



                <target name="test" depends="buildtest" description="Run the tests">
                    <taskdef resource="testngtasks" classpath="${testng.jar}"/>
                    <path id="test.path">
                        <path path="${test.dir}"/>
                        <fileset dir="${lib.dir}/test">
                            <include name="*.jar"/>
                        </fileset>
                        <path path="${bootstrap.dir}"/>
                        <path refid="build.classpath"/>
                    </path>
                    <delete dir="${bootstrap.dir}/data/hypersonic"/>
                    <testng outputdir="${basedir}/test-report">
                        <classpath refid="test.path"/>
                        <!--<jvmarg value="-Demma.coverage.out.file=${coverage.ec}" />-->
                        <jvmarg line="-Djava.awt.headless=true"/>
                        <!--added for JDK6 compatibility with JBoss embedded-->
                        <jvmarg line="-Dsun.lang.ClassLoader.allowArraySyntax=true"/>
                        <xmlfileset dir="${test.dir}" includes="*Test.xml"/>
                    </testng>
                </target>
            









            • 3. Re: Seam TestNG tests and Hudson CI problem
              slawek t Novice

              That is the line



              <myproject>/test-report/**/*.xml

              which resolved my problem.
              Previously I was trying to poined testng-results.xml file directly in Publish JUnit test result report but it didn't work.


              Thank you!