JUnit pass rate no longer showing with Dashboard 1.9

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

JUnit pass rate no longer showing with Dashboard 1.9

Wim Deblauwe
Hi,

my JUnit passrates are no longer showing when using dashboard version
1.9. I traced the problem down to the JUnit aggregator. It contains
these linen:

      <j:choose>
        <x:set var="nbTests" select="sum($doc/testsuites/testsuite/@tests)"/>
        <a:echo>nr of tests: ${nbTests}</a:echo>
        <j:when test="${nbTests != 0}">
          <x:parse var="doc" xml="${artifactAsFile}"/>
          <x:expr select="floor(100 - 100 *
(sum($doc/testsuites/testsuite/@failures)  +
sum($doc/testsuites/testsuite/@errors)) div
sum($doc/testsuites/testsuite/@tests))"/>
        %
        </j:when>
        <j:otherwise>
          <j:expr value="-"/>
        </j:otherwise>
      </j:choose>

The problem is that the xml file is being parsed after the nr of unit
tests has been calculated (using the $doc variable, but it is not
initialized yet). The solution: move the parsing of the xml file
higher, like this:

      <x:parse var="doc" xml="${artifactAsFile}"/>
      <j:choose>
        <x:set var="nbTests" select="sum($doc/testsuites/testsuite/@tests)"/>
        <a:echo>nr of tests: ${nbTests}</a:echo>
        <j:when test="${nbTests != 0}">
          <x:expr select="floor(100 - 100 *
(sum($doc/testsuites/testsuite/@failures)  +
sum($doc/testsuites/testsuite/@errors)) div
sum($doc/testsuites/testsuite/@tests))"/>
        %
        </j:when>
        <j:otherwise>
          <j:expr value="-"/>
        </j:otherwise>
      </j:choose>

regards,

Wim

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: JUnit pass rate no longer showing with Dashboard 1.9

Vincent Massol
Hi Wim,

Thanks. Could you please open a JIRA issue and attach your solution as a
patch to it?

Thanks
-Vincent

> -----Original Message-----
> From: Wim Deblauwe [mailto:[hidden email]]
> Sent: jeudi 26 mai 2005 10:42
> To: Maven Users List
> Subject: JUnit pass rate no longer showing with Dashboard 1.9
>
> Hi,
>
> my JUnit passrates are no longer showing when using dashboard version
> 1.9. I traced the problem down to the JUnit aggregator. It contains
> these linen:
>
>       <j:choose>
>         <x:set var="nbTests"
> select="sum($doc/testsuites/testsuite/@tests)"/>
>         <a:echo>nr of tests: ${nbTests}</a:echo>
>         <j:when test="${nbTests != 0}">
>           <x:parse var="doc" xml="${artifactAsFile}"/>
>           <x:expr select="floor(100 - 100 *
> (sum($doc/testsuites/testsuite/@failures)  +
> sum($doc/testsuites/testsuite/@errors)) div
> sum($doc/testsuites/testsuite/@tests))"/>
>         %
>         </j:when>
>         <j:otherwise>
>           <j:expr value="-"/>
>         </j:otherwise>
>       </j:choose>
>
> The problem is that the xml file is being parsed after the nr of unit
> tests has been calculated (using the $doc variable, but it is not
> initialized yet). The solution: move the parsing of the xml file
> higher, like this:
>
>       <x:parse var="doc" xml="${artifactAsFile}"/>
>       <j:choose>
>         <x:set var="nbTests"
> select="sum($doc/testsuites/testsuite/@tests)"/>
>         <a:echo>nr of tests: ${nbTests}</a:echo>
>         <j:when test="${nbTests != 0}">
>           <x:expr select="floor(100 - 100 *
> (sum($doc/testsuites/testsuite/@failures)  +
> sum($doc/testsuites/testsuite/@errors)) div
> sum($doc/testsuites/testsuite/@tests))"/>
>         %
>         </j:when>
>         <j:otherwise>
>           <j:expr value="-"/>
>         </j:otherwise>
>       </j:choose>
>
> regards,
>
> Wim
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]



       

       
               
_____________________________________________________________________________
D?couvrez le nouveau Yahoo! Mail : 1 Go d'espace de stockage pour vos mails, photos et vid?os !
Cr?ez votre Yahoo! Mail sur http://fr.mail.yahoo.com


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: JUnit pass rate no longer showing with Dashboard 1.9

Wim Deblauwe
In reply to this post by Wim Deblauwe
Done: http://jira.werken.com/browse/MPDASHBOARD-26

regards,

Wim

PS: Version 1.9 is still marked as "unreleased" in JIRA

2005/5/26, Vincent Massol <[hidden email]>:

> Hi Wim,
>
> Thanks. Could you please open a JIRA issue and attach your solution as a
> patch to it?
>
> Thanks
> -Vincent
>
> > -----Original Message-----
> > From: Wim Deblauwe [mailto:[hidden email]]
> > Sent: jeudi 26 mai 2005 10:42
> > To: Maven Users List
> > Subject: JUnit pass rate no longer showing with Dashboard 1.9
> >
> > Hi,
> >
> > my JUnit passrates are no longer showing when using dashboard version
> > 1.9. I traced the problem down to the JUnit aggregator. It contains
> > these linen:
> >
> >       <j:choose>
> >         <x:set var="nbTests"
> > select="sum($doc/testsuites/testsuite/@tests)"/>
> >         <a:echo>nr of tests: ${nbTests}</a:echo>
> >         <j:when test="${nbTests != 0}">
> >           <x:parse var="doc" xml="${artifactAsFile}"/>
> >           <x:expr select="floor(100 - 100 *
> > (sum($doc/testsuites/testsuite/@failures)  +
> > sum($doc/testsuites/testsuite/@errors)) div
> > sum($doc/testsuites/testsuite/@tests))"/>
> >               %
> >         </j:when>
> >         <j:otherwise>
> >           <j:expr value="-"/>
> >         </j:otherwise>
> >       </j:choose>
> >
> > The problem is that the xml file is being parsed after the nr of unit
> > tests has been calculated (using the $doc variable, but it is not
> > initialized yet). The solution: move the parsing of the xml file
> > higher, like this:
> >
> >       <x:parse var="doc" xml="${artifactAsFile}"/>
> >       <j:choose>
> >         <x:set var="nbTests"
> > select="sum($doc/testsuites/testsuite/@tests)"/>
> >         <a:echo>nr of tests: ${nbTests}</a:echo>
> >         <j:when test="${nbTests != 0}">
> >           <x:expr select="floor(100 - 100 *
> > (sum($doc/testsuites/testsuite/@failures)  +
> > sum($doc/testsuites/testsuite/@errors)) div
> > sum($doc/testsuites/testsuite/@tests))"/>
> >               %
> >         </j:when>
> >         <j:otherwise>
> >           <j:expr value="-"/>
> >         </j:otherwise>
> >       </j:choose>
> >
> > regards,
> >
> > Wim
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> > For additional commands, e-mail: [hidden email]
>
> _____________________________________________________________________________
> Découvrez le nouveau Yahoo! Mail : 1 Go d'espace de stockage pour vos mails, photos et vidéos !
> Créez votre Yahoo! Mail sur http://fr.mail.yahoo.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: JUnit pass rate no longer showing with Dashboard 1.9

Vincent Massol


> -----Original Message-----
> From: Wim Deblauwe [mailto:[hidden email]]
> Sent: jeudi 26 mai 2005 11:04
> To: Maven Users List
> Subject: Re: JUnit pass rate no longer showing with Dashboard 1.9

[snip]

> PS: Version 1.9 is still marked as "unreleased" in JIRA

Maybe that's because it *is* unreleased! ;-)

-Vincent


       

       
               
_____________________________________________________________________________
D?couvrez le nouveau Yahoo! Mail : 1 Go d'espace de stockage pour vos mails, photos et vid?os !
Cr?ez votre Yahoo! Mail sur http://fr.mail.yahoo.com


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: JUnit pass rate no longer showing with Dashboard 1.9

Wim Deblauwe
In reply to this post by Wim Deblauwe
> > PS: Version 1.9 is still marked as "unreleased" in JIRA
>
> Maybe that's because it *is* unreleased! ;-)
>
> -Vincent

Whoops, just mixed up the Clover and Dashboard plugin version. Indeed,
Dashboard is at version 1.8 :)
I just looked at the JIRA issue, but I don't find any button I can
push to change it to version 1.8.

regards,

Wim

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: JUnit pass rate no longer showing with Dashboard 1.9

Vincent Massol


> -----Original Message-----
> From: Wim Deblauwe [mailto:[hidden email]]
> Sent: jeudi 26 mai 2005 11:27
> To: Maven Users List
> Subject: Re: JUnit pass rate no longer showing with Dashboard 1.9
>
> > > PS: Version 1.9 is still marked as "unreleased" in JIRA
> >
> > Maybe that's because it *is* unreleased! ;-)
> >
> > -Vincent
>
> Whoops, just mixed up the Clover and Dashboard plugin version. Indeed,
> Dashboard is at version 1.8 :)
> I just looked at the JIRA issue, but I don't find any button I can
> push to change it to version 1.8.

You need to edit the issue. I've just done it for you.

-Vincent


       

       
               
_____________________________________________________________________________
D?couvrez le nouveau Yahoo! Mail : 1 Go d'espace de stockage pour vos mails, photos et vid?os !
Cr?ez votre Yahoo! Mail sur http://fr.mail.yahoo.com


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]