public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH] Fix genhtml.pl (was "Re: HTML not reporting number of Failed test cases")
@ 2009-10-13  2:08 Garrett Cooper
  2009-10-13  2:12 ` Garrett Cooper
  2009-10-15 14:51 ` Subrata Modak
  0 siblings, 2 replies; 5+ messages in thread
From: Garrett Cooper @ 2009-10-13  2:08 UTC (permalink / raw)
  To: rohit verma; +Cc: ltp-list, naresh kamboju

On Fri, Oct 9, 2009 at 3:00 AM, rohit verma <rohit.170309@gmail.com> wrote:
> Hi,
>
> Thanks Naresh for pointing out the issue in the HTML report. I had
> also noticed the issue in my test reports.
>
> However, I wish to confirm that the issue being mentioned is not a
> side-effect of the fix that I had posted for the pan driver.
> If you compare the HTML reports from the previous releases and the
> recent one, you can notice all the tags - FAIL, WARN, BROK, PASS,CONF
> & RETR are now prefixed by ' T ' for reasons not known to me
> (resulting in - TFAIL, TPASS etc).
>
> Now, if you check ltp-full-20090831/tools/genhtml.pl file you can see
> all that old tags (FAIL, WARN, etc) are used instead of the new
> ones(tags). As a result the numbers are not updated in the summary in
> HTML report. Also FAIL/WARN/BROK test-cases are not uniquely colored
> like in the old versions of LTP.
>
> Please check the same.
> If possible I will generate a patch and submit the same.
>
> On Wed, Oct 7, 2009 at 4:43 PM, naresh kamboju <naresh.kernel@gmail.com> wrote:
>> Hi,
>>
>> I think you have noticed difference in the HTML file generation.
>> HTML file is not reporting number of failure test cases
>> in summary and failed column with different color.
>> Some changes are made by Rohit recently.
>>
>> Rohit,
>> Please investigate the changes made to HTML file generator.
>>
>> You can refer the results logs share in LTP release in the below link for
>> X86
>> (ltp-full-20090930_results_kernel-2.6.31_architecture-i386.tgz)
>> Ia64
>> (ltp-full-20090930_results_kernel-2.6.23.13_architecture-ia64.tgz)

Try this.

Fix genhtml.pl so that it functions with the new T-prefixing in the
lib/tst_res.c result codes.

Signed-off-by: Garrett Cooper <yanegomi@gmail.com>

Index: contrib/ltp/src/tools/genhtml.pl
===================================================================
--- src/tools/.CC/cache/genhtml.pl@@/main/ltp-upgrade/1 2009-10-12
19:08:28.000000000 -0700
+++ src/tools/genhtml.pl        2009-10-12 19:08:18.000000000 -0700
@@ -179,31 +179,31 @@
                         }
                         if ( $flag2 == 1 ) {
                            $row_line = $row_line . "$line \n";
-                           if ($line =~ /\ FAIL\ / ) {
+                           if ($line =~ /\ TFAIL\ / ) {
                                $detected_fail = 1;
                                if ( $failed_test_counter_flag == 0 ) {
                                    $failed_test_counter++;
                                    $failed_test_counter_flag=1;
                                }
-                           } elsif ($line =~ /\ BROK\ / ) {
+                           } elsif ($line =~ /\ TBROK\ / ) {
                                $detected_brok = 1;
                                if ( $brok_test_counter_flag == 0 ) {
                                    $brok_test_counter++;
                                    $brok_test_counter_flag=1;
                                }
-                           } elsif ($line =~ /\ WARN\ / ) {
+                           } elsif ($line =~ /\ TWARN\ / ) {
                                $detected_warn = 1;
                                if ( $warn_test_counter_flag == 0 ) {
                                    $warn_test_counter++;
                                    $warn_test_counter_flag=1;
                                }
-                           } elsif ($line =~ /\ RETR\ / ) {
+                           } elsif ($line =~ /\ TRETR\ / ) {
                                $detected_retr = 1;
                                if ( $retr_test_counter_flag == 0 ) {
                                    $retr_test_counter++;
                                    $retr_test_counter_flag=1;
                                }
-                           } elsif ($line =~ /\ CONF\ / ) {
+                           } elsif ($line =~ /\ TCONF\ / ) {
                                $detected_conf = 1;
                                if ( $conf_test_counter_flag == 0 ) {
                                    $conf_test_counter++;
@@ -251,3 +251,5 @@
 print "<tr><td><strong>Hostname</strong>  </td> <td><strong>";
 $hostname=system("uname -n");             chop($hostname);
 print " $hostname </strong></td></tr></tbody></table></div></body></html>\n";
+
+# vim: syntax=perl

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [LTP] [PATCH] Fix genhtml.pl (was "Re: HTML not reporting number of Failed test cases")
  2009-10-13  2:08 [LTP] [PATCH] Fix genhtml.pl (was "Re: HTML not reporting number of Failed test cases") Garrett Cooper
@ 2009-10-13  2:12 ` Garrett Cooper
  2009-10-13 14:02   ` naresh kamboju
  2009-10-15 14:51 ` Subrata Modak
  1 sibling, 1 reply; 5+ messages in thread
From: Garrett Cooper @ 2009-10-13  2:12 UTC (permalink / raw)
  To: rohit verma; +Cc: ltp-list, naresh kamboju

On Mon, Oct 12, 2009 at 7:08 PM, Garrett Cooper <yanegomi@gmail.com> wrote:
> On Fri, Oct 9, 2009 at 3:00 AM, rohit verma <rohit.170309@gmail.com> wrote:
>> Hi,
>>
>> Thanks Naresh for pointing out the issue in the HTML report. I had
>> also noticed the issue in my test reports.
>>
>> However, I wish to confirm that the issue being mentioned is not a
>> side-effect of the fix that I had posted for the pan driver.
>> If you compare the HTML reports from the previous releases and the
>> recent one, you can notice all the tags - FAIL, WARN, BROK, PASS,CONF
>> & RETR are now prefixed by ' T ' for reasons not known to me
>> (resulting in - TFAIL, TPASS etc).
>>
>> Now, if you check ltp-full-20090831/tools/genhtml.pl file you can see
>> all that old tags (FAIL, WARN, etc) are used instead of the new
>> ones(tags). As a result the numbers are not updated in the summary in
>> HTML report. Also FAIL/WARN/BROK test-cases are not uniquely colored
>> like in the old versions of LTP.
>>
>> Please check the same.
>> If possible I will generate a patch and submit the same.
>>
>> On Wed, Oct 7, 2009 at 4:43 PM, naresh kamboju <naresh.kernel@gmail.com> wrote:
>>> Hi,
>>>
>>> I think you have noticed difference in the HTML file generation.
>>> HTML file is not reporting number of failure test cases
>>> in summary and failed column with different color.
>>> Some changes are made by Rohit recently.
>>>
>>> Rohit,
>>> Please investigate the changes made to HTML file generator.
>>>
>>> You can refer the results logs share in LTP release in the below link for
>>> X86
>>> (ltp-full-20090930_results_kernel-2.6.31_architecture-i386.tgz)
>>> Ia64
>>> (ltp-full-20090930_results_kernel-2.6.23.13_architecture-ia64.tgz)
>
> Try this.
>
> Fix genhtml.pl so that it functions with the new T-prefixing in the
> lib/tst_res.c result codes.
>
> Signed-off-by: Garrett Cooper <yanegomi@gmail.com>
>
> Index: contrib/ltp/src/tools/genhtml.pl
> ===================================================================
> --- src/tools/.CC/cache/genhtml.pl@@/main/ltp-upgrade/1 2009-10-12
> 19:08:28.000000000 -0700
> +++ src/tools/genhtml.pl        2009-10-12 19:08:18.000000000 -0700
> @@ -179,31 +179,31 @@
>                         }
>                         if ( $flag2 == 1 ) {
>                            $row_line = $row_line . "$line \n";
> -                           if ($line =~ /\ FAIL\ / ) {
> +                           if ($line =~ /\ TFAIL\ / ) {
>                                $detected_fail = 1;
>                                if ( $failed_test_counter_flag == 0 ) {
>                                    $failed_test_counter++;
>                                    $failed_test_counter_flag=1;
>                                }
> -                           } elsif ($line =~ /\ BROK\ / ) {
> +                           } elsif ($line =~ /\ TBROK\ / ) {
>                                $detected_brok = 1;
>                                if ( $brok_test_counter_flag == 0 ) {
>                                    $brok_test_counter++;
>                                    $brok_test_counter_flag=1;
>                                }
> -                           } elsif ($line =~ /\ WARN\ / ) {
> +                           } elsif ($line =~ /\ TWARN\ / ) {
>                                $detected_warn = 1;
>                                if ( $warn_test_counter_flag == 0 ) {
>                                    $warn_test_counter++;
>                                    $warn_test_counter_flag=1;
>                                }
> -                           } elsif ($line =~ /\ RETR\ / ) {
> +                           } elsif ($line =~ /\ TRETR\ / ) {
>                                $detected_retr = 1;
>                                if ( $retr_test_counter_flag == 0 ) {
>                                    $retr_test_counter++;
>                                    $retr_test_counter_flag=1;
>                                }
> -                           } elsif ($line =~ /\ CONF\ / ) {
> +                           } elsif ($line =~ /\ TCONF\ / ) {
>                                $detected_conf = 1;
>                                if ( $conf_test_counter_flag == 0 ) {
>                                    $conf_test_counter++;
> @@ -251,3 +251,5 @@
>  print "<tr><td><strong>Hostname</strong>  </td> <td><strong>";
>  $hostname=system("uname -n");             chop($hostname);
>  print " $hostname </strong></td></tr></tbody></table></div></body></html>\n";
> +
> +# vim: syntax=perl

    This was the checkin that changed the output format, BTW:
Cheers,
-Garrett

----------------------------------------------------------------------------------------------------------

Update of /cvsroot/ltp/ltp/lib
In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv24617/lib

Modified Files:
       tst_res.c
Log Message:
extend the test result to a bit field so we can extend the output further

Index: tst_res.c
===================================================================
RCS file: /cvsroot/ltp/ltp/lib/tst_res.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** tst_res.c   9 Jun 2009 16:01:20 -0000       1.8
--- tst_res.c   20 Jul 2009 02:42:32 -0000      1.9
***************
*** 116,119 ****
--- 116,120 ----
 #include <unistd.h>
 #include "test.h"
+ #include "usctest.h"

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [LTP] [PATCH] Fix genhtml.pl (was "Re: HTML not reporting number of Failed test cases")
  2009-10-13  2:12 ` Garrett Cooper
@ 2009-10-13 14:02   ` naresh kamboju
  0 siblings, 0 replies; 5+ messages in thread
From: naresh kamboju @ 2009-10-13 14:02 UTC (permalink / raw)
  To: Garrett Cooper; +Cc: ltp-list, rohit.170309

Thank you very much Garrett.
Its working at my end.

Best regards,
Naresh Kamboju


On Tue, Oct 13, 2009 at 7:42 AM, Garrett Cooper <yanegomi@gmail.com> wrote:
> On Mon, Oct 12, 2009 at 7:08 PM, Garrett Cooper <yanegomi@gmail.com> wrote:
>> On Fri, Oct 9, 2009 at 3:00 AM, rohit verma <rohit.170309@gmail.com> wrote:
>>> Hi,
>>>
>>> Thanks Naresh for pointing out the issue in the HTML report. I had
>>> also noticed the issue in my test reports.
>>>
>>> However, I wish to confirm that the issue being mentioned is not a
>>> side-effect of the fix that I had posted for the pan driver.
>>> If you compare the HTML reports from the previous releases and the
>>> recent one, you can notice all the tags - FAIL, WARN, BROK, PASS,CONF
>>> & RETR are now prefixed by ' T ' for reasons not known to me
>>> (resulting in - TFAIL, TPASS etc).
>>>
>>> Now, if you check ltp-full-20090831/tools/genhtml.pl file you can see
>>> all that old tags (FAIL, WARN, etc) are used instead of the new
>>> ones(tags). As a result the numbers are not updated in the summary in
>>> HTML report. Also FAIL/WARN/BROK test-cases are not uniquely colored
>>> like in the old versions of LTP.
>>>
>>> Please check the same.
>>> If possible I will generate a patch and submit the same.
>>>
>>> On Wed, Oct 7, 2009 at 4:43 PM, naresh kamboju <naresh.kernel@gmail.com> wrote:
>>>> Hi,
>>>>
>>>> I think you have noticed difference in the HTML file generation.
>>>> HTML file is not reporting number of failure test cases
>>>> in summary and failed column with different color.
>>>> Some changes are made by Rohit recently.
>>>>
>>>> Rohit,
>>>> Please investigate the changes made to HTML file generator.
>>>>
>>>> You can refer the results logs share in LTP release in the below link for
>>>> X86
>>>> (ltp-full-20090930_results_kernel-2.6.31_architecture-i386.tgz)
>>>> Ia64
>>>> (ltp-full-20090930_results_kernel-2.6.23.13_architecture-ia64.tgz)
>>
>> Try this.
>>
>> Fix genhtml.pl so that it functions with the new T-prefixing in the
>> lib/tst_res.c result codes.
>>
>> Signed-off-by: Garrett Cooper <yanegomi@gmail.com>
>>
>> Index: contrib/ltp/src/tools/genhtml.pl
>> ===================================================================
>> --- src/tools/.CC/cache/genhtml.pl@@/main/ltp-upgrade/1 2009-10-12
>> 19:08:28.000000000 -0700
>> +++ src/tools/genhtml.pl        2009-10-12 19:08:18.000000000 -0700
>> @@ -179,31 +179,31 @@
>>                         }
>>                         if ( $flag2 == 1 ) {
>>                            $row_line = $row_line . "$line \n";
>> -                           if ($line =~ /\ FAIL\ / ) {
>> +                           if ($line =~ /\ TFAIL\ / ) {
>>                                $detected_fail = 1;
>>                                if ( $failed_test_counter_flag == 0 ) {
>>                                    $failed_test_counter++;
>>                                    $failed_test_counter_flag=1;
>>                                }
>> -                           } elsif ($line =~ /\ BROK\ / ) {
>> +                           } elsif ($line =~ /\ TBROK\ / ) {
>>                                $detected_brok = 1;
>>                                if ( $brok_test_counter_flag == 0 ) {
>>                                    $brok_test_counter++;
>>                                    $brok_test_counter_flag=1;
>>                                }
>> -                           } elsif ($line =~ /\ WARN\ / ) {
>> +                           } elsif ($line =~ /\ TWARN\ / ) {
>>                                $detected_warn = 1;
>>                                if ( $warn_test_counter_flag == 0 ) {
>>                                    $warn_test_counter++;
>>                                    $warn_test_counter_flag=1;
>>                                }
>> -                           } elsif ($line =~ /\ RETR\ / ) {
>> +                           } elsif ($line =~ /\ TRETR\ / ) {
>>                                $detected_retr = 1;
>>                                if ( $retr_test_counter_flag == 0 ) {
>>                                    $retr_test_counter++;
>>                                    $retr_test_counter_flag=1;
>>                                }
>> -                           } elsif ($line =~ /\ CONF\ / ) {
>> +                           } elsif ($line =~ /\ TCONF\ / ) {
>>                                $detected_conf = 1;
>>                                if ( $conf_test_counter_flag == 0 ) {
>>                                    $conf_test_counter++;
>> @@ -251,3 +251,5 @@
>>  print "<tr><td><strong>Hostname</strong>  </td> <td><strong>";
>>  $hostname=system("uname -n");             chop($hostname);
>>  print " $hostname </strong></td></tr></tbody></table></div></body></html>\n";
>> +
>> +# vim: syntax=perl
>
>    This was the checkin that changed the output format, BTW:
> Cheers,
> -Garrett
>
> ----------------------------------------------------------------------------------------------------------
>
> Update of /cvsroot/ltp/ltp/lib
> In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv24617/lib
>
> Modified Files:
>       tst_res.c
> Log Message:
> extend the test result to a bit field so we can extend the output further
>
> Index: tst_res.c
> ===================================================================
> RCS file: /cvsroot/ltp/ltp/lib/tst_res.c,v
> retrieving revision 1.8
> retrieving revision 1.9
> diff -C2 -d -r1.8 -r1.9
> *** tst_res.c   9 Jun 2009 16:01:20 -0000       1.8
> --- tst_res.c   20 Jul 2009 02:42:32 -0000      1.9
> ***************
> *** 116,119 ****
> --- 116,120 ----
>  #include <unistd.h>
>  #include "test.h"
> + #include "usctest.h"
>

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [LTP] [PATCH] Fix genhtml.pl (was "Re: HTML not reporting number of Failed test cases")
  2009-10-13  2:08 [LTP] [PATCH] Fix genhtml.pl (was "Re: HTML not reporting number of Failed test cases") Garrett Cooper
  2009-10-13  2:12 ` Garrett Cooper
@ 2009-10-15 14:51 ` Subrata Modak
  2009-10-15 18:46   ` Garrett Cooper
  1 sibling, 1 reply; 5+ messages in thread
From: Subrata Modak @ 2009-10-15 14:51 UTC (permalink / raw)
  To: Garrett Cooper; +Cc: rohit verma, naresh kamboju, ltp-list

On Mon, 2009-10-12 at 19:08 -0700, Garrett Cooper wrote: 
> On Fri, Oct 9, 2009 at 3:00 AM, rohit verma <rohit.170309@gmail.com> wrote:
> > Hi,
> >
> > Thanks Naresh for pointing out the issue in the HTML report. I had
> > also noticed the issue in my test reports.
> >
> > However, I wish to confirm that the issue being mentioned is not a
> > side-effect of the fix that I had posted for the pan driver.
> > If you compare the HTML reports from the previous releases and the
> > recent one, you can notice all the tags - FAIL, WARN, BROK, PASS,CONF
> > & RETR are now prefixed by ' T ' for reasons not known to me
> > (resulting in - TFAIL, TPASS etc).
> >
> > Now, if you check ltp-full-20090831/tools/genhtml.pl file you can see
> > all that old tags (FAIL, WARN, etc) are used instead of the new
> > ones(tags). As a result the numbers are not updated in the summary in
> > HTML report. Also FAIL/WARN/BROK test-cases are not uniquely colored
> > like in the old versions of LTP.
> >
> > Please check the same.
> > If possible I will generate a patch and submit the same.
> >
> > On Wed, Oct 7, 2009 at 4:43 PM, naresh kamboju <naresh.kernel@gmail.com> wrote:
> >> Hi,
> >>
> >> I think you have noticed difference in the HTML file generation.
> >> HTML file is not reporting number of failure test cases
> >> in summary and failed column with different color.
> >> Some changes are made by Rohit recently.
> >>
> >> Rohit,
> >> Please investigate the changes made to HTML file generator.
> >>
> >> You can refer the results logs share in LTP release in the below link for
> >> X86
> >> (ltp-full-20090930_results_kernel-2.6.31_architecture-i386.tgz)
> >> Ia64
> >> (ltp-full-20090930_results_kernel-2.6.23.13_architecture-ia64.tgz)
> 
> Try this.
> 
> Fix genhtml.pl so that it functions with the new T-prefixing in the
> lib/tst_res.c result codes.
> 
> Signed-off-by: Garrett Cooper <yanegomi@gmail.com>

Directly checkin this as well:

patching file tools/genhtml.pl
Hunk #1 FAILED at 179.
Hunk #2 succeeded at 251 with fuzz 2.
1 out of 2 hunks FAILED -- saving rejects to file tools/genhtml.pl.rej

Regards--
Subrata

> 
> Index: contrib/ltp/src/tools/genhtml.pl
> ===================================================================
> --- src/tools/.CC/cache/genhtml.pl@@/main/ltp-upgrade/1 2009-10-12
> 19:08:28.000000000 -0700
> +++ src/tools/genhtml.pl        2009-10-12 19:08:18.000000000 -0700
> @@ -179,31 +179,31 @@
>                          }
>                          if ( $flag2 == 1 ) {
>                             $row_line = $row_line . "$line \n";
> -                           if ($line =~ /\ FAIL\ / ) {
> +                           if ($line =~ /\ TFAIL\ / ) {
>                                 $detected_fail = 1;
>                                 if ( $failed_test_counter_flag == 0 ) {
>                                     $failed_test_counter++;
>                                     $failed_test_counter_flag=1;
>                                 }
> -                           } elsif ($line =~ /\ BROK\ / ) {
> +                           } elsif ($line =~ /\ TBROK\ / ) {
>                                 $detected_brok = 1;
>                                 if ( $brok_test_counter_flag == 0 ) {
>                                     $brok_test_counter++;
>                                     $brok_test_counter_flag=1;
>                                 }
> -                           } elsif ($line =~ /\ WARN\ / ) {
> +                           } elsif ($line =~ /\ TWARN\ / ) {
>                                 $detected_warn = 1;
>                                 if ( $warn_test_counter_flag == 0 ) {
>                                     $warn_test_counter++;
>                                     $warn_test_counter_flag=1;
>                                 }
> -                           } elsif ($line =~ /\ RETR\ / ) {
> +                           } elsif ($line =~ /\ TRETR\ / ) {
>                                 $detected_retr = 1;
>                                 if ( $retr_test_counter_flag == 0 ) {
>                                     $retr_test_counter++;
>                                     $retr_test_counter_flag=1;
>                                 }
> -                           } elsif ($line =~ /\ CONF\ / ) {
> +                           } elsif ($line =~ /\ TCONF\ / ) {
>                                 $detected_conf = 1;
>                                 if ( $conf_test_counter_flag == 0 ) {
>                                     $conf_test_counter++;
> @@ -251,3 +251,5 @@
>  print "<tr><td><strong>Hostname</strong>  </td> <td><strong>";
>  $hostname=system("uname -n");             chop($hostname);
>  print " $hostname </strong></td></tr></tbody></table></div></body></html>\n";
> +
> +# vim: syntax=perl
> 
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry(R) Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay 
> ahead of the curve. Join us from November 9 - 12, 2009. Register now!
> http://p.sf.net/sfu/devconference
> _______________________________________________
> Ltp-list mailing list
> Ltp-list@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ltp-list


------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [LTP] [PATCH] Fix genhtml.pl (was "Re: HTML not reporting number of Failed test cases")
  2009-10-15 14:51 ` Subrata Modak
@ 2009-10-15 18:46   ` Garrett Cooper
  0 siblings, 0 replies; 5+ messages in thread
From: Garrett Cooper @ 2009-10-15 18:46 UTC (permalink / raw)
  To: subrata; +Cc: rohit verma, naresh kamboju, ltp-list

On Thu, Oct 15, 2009 at 7:51 AM, Subrata Modak
<subrata@linux.vnet.ibm.com> wrote:
> On Mon, 2009-10-12 at 19:08 -0700, Garrett Cooper wrote:
>> On Fri, Oct 9, 2009 at 3:00 AM, rohit verma <rohit.170309@gmail.com> wrote:
>> > Hi,
>> >
>> > Thanks Naresh for pointing out the issue in the HTML report. I had
>> > also noticed the issue in my test reports.
>> >
>> > However, I wish to confirm that the issue being mentioned is not a
>> > side-effect of the fix that I had posted for the pan driver.
>> > If you compare the HTML reports from the previous releases and the
>> > recent one, you can notice all the tags - FAIL, WARN, BROK, PASS,CONF
>> > & RETR are now prefixed by ' T ' for reasons not known to me
>> > (resulting in - TFAIL, TPASS etc).
>> >
>> > Now, if you check ltp-full-20090831/tools/genhtml.pl file you can see
>> > all that old tags (FAIL, WARN, etc) are used instead of the new
>> > ones(tags). As a result the numbers are not updated in the summary in
>> > HTML report. Also FAIL/WARN/BROK test-cases are not uniquely colored
>> > like in the old versions of LTP.
>> >
>> > Please check the same.
>> > If possible I will generate a patch and submit the same.
>> >
>> > On Wed, Oct 7, 2009 at 4:43 PM, naresh kamboju <naresh.kernel@gmail.com> wrote:
>> >> Hi,
>> >>
>> >> I think you have noticed difference in the HTML file generation.
>> >> HTML file is not reporting number of failure test cases
>> >> in summary and failed column with different color.
>> >> Some changes are made by Rohit recently.
>> >>
>> >> Rohit,
>> >> Please investigate the changes made to HTML file generator.
>> >>
>> >> You can refer the results logs share in LTP release in the below link for
>> >> X86
>> >> (ltp-full-20090930_results_kernel-2.6.31_architecture-i386.tgz)
>> >> Ia64
>> >> (ltp-full-20090930_results_kernel-2.6.23.13_architecture-ia64.tgz)
>>
>> Try this.
>>
>> Fix genhtml.pl so that it functions with the new T-prefixing in the
>> lib/tst_res.c result codes.
>>
>> Signed-off-by: Garrett Cooper <yanegomi@gmail.com>
>
> Directly checkin this as well:
>
> patching file tools/genhtml.pl
> Hunk #1 FAILED at 179.
> Hunk #2 succeeded at 251 with fuzz 2.
> 1 out of 2 hunks FAILED -- saving rejects to file tools/genhtml.pl.rej
>
> Regards--
> Subrata
>
>>
>> Index: contrib/ltp/src/tools/genhtml.pl
>> ===================================================================
>> --- src/tools/.CC/cache/genhtml.pl@@/main/ltp-upgrade/1 2009-10-12
>> 19:08:28.000000000 -0700
>> +++ src/tools/genhtml.pl        2009-10-12 19:08:18.000000000 -0700
>> @@ -179,31 +179,31 @@
>>                          }
>>                          if ( $flag2 == 1 ) {
>>                             $row_line = $row_line . "$line \n";
>> -                           if ($line =~ /\ FAIL\ / ) {
>> +                           if ($line =~ /\ TFAIL\ / ) {
>>                                 $detected_fail = 1;
>>                                 if ( $failed_test_counter_flag == 0 ) {
>>                                     $failed_test_counter++;
>>                                     $failed_test_counter_flag=1;
>>                                 }
>> -                           } elsif ($line =~ /\ BROK\ / ) {
>> +                           } elsif ($line =~ /\ TBROK\ / ) {
>>                                 $detected_brok = 1;
>>                                 if ( $brok_test_counter_flag == 0 ) {
>>                                     $brok_test_counter++;
>>                                     $brok_test_counter_flag=1;
>>                                 }
>> -                           } elsif ($line =~ /\ WARN\ / ) {
>> +                           } elsif ($line =~ /\ TWARN\ / ) {
>>                                 $detected_warn = 1;
>>                                 if ( $warn_test_counter_flag == 0 ) {
>>                                     $warn_test_counter++;
>>                                     $warn_test_counter_flag=1;
>>                                 }
>> -                           } elsif ($line =~ /\ RETR\ / ) {
>> +                           } elsif ($line =~ /\ TRETR\ / ) {
>>                                 $detected_retr = 1;
>>                                 if ( $retr_test_counter_flag == 0 ) {
>>                                     $retr_test_counter++;
>>                                     $retr_test_counter_flag=1;
>>                                 }
>> -                           } elsif ($line =~ /\ CONF\ / ) {
>> +                           } elsif ($line =~ /\ TCONF\ / ) {
>>                                 $detected_conf = 1;
>>                                 if ( $conf_test_counter_flag == 0 ) {
>>                                     $conf_test_counter++;
>> @@ -251,3 +251,5 @@
>>  print "<tr><td><strong>Hostname</strong>  </td> <td><strong>";
>>  $hostname=system("uname -n");             chop($hostname);
>>  print " $hostname </strong></td></tr></tbody></table></div></body></html>\n";
>> +
>> +# vim: syntax=perl

Subrata,
    This was already checked into CVS because I was 100% sure that my
change was correct (sorry ><).
Thanks,
-Garrett

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-10-15 18:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-10-13  2:08 [LTP] [PATCH] Fix genhtml.pl (was "Re: HTML not reporting number of Failed test cases") Garrett Cooper
2009-10-13  2:12 ` Garrett Cooper
2009-10-13 14:02   ` naresh kamboju
2009-10-15 14:51 ` Subrata Modak
2009-10-15 18:46   ` Garrett Cooper

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox