[PATCH] improvement to output of 10 slowest tests

Michael Adam obnox at samba.org
Mon Oct 27 16:40:07 MDT 2014


On 2014-10-27 at 11:04 -0700, Matthieu Patou wrote:
> On 10/27/2014 06:37 AM, Michael Adam wrote:
> >review/push appreciated
> >
> >Thanks - Michael
> 
> >+$max = @sorted if (($max <= 0) or ($max > @sorted));
> If max is undefined what's the expected behavior ?

$max is never undefined in that script:
It is initialized to 0 and set to $ARGV[1]
if that array element exists.

So the worst thing that can happen is that the string
$ARGV[1] does not represent a (decimal) number.

Attached find a patch that adds an error treatment
for this case (ARGV[1] not a decimal number).

Also attached a patch that fixes the output of the
slowest tests in case "--selftest-prefix" is specified
and different from "st".

Review/push/comment appreciated.

Thanks - Michael
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-script-show_testsuite_time-error-out-if-number-argum.patch
Type: text/x-diff
Size: 709 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20141027/fd602d94/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-build-fix-check-for-subunit-file-when-selftest-prefi.patch
Type: text/x-diff
Size: 1104 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20141027/fd602d94/attachment-0001.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20141027/fd602d94/attachment.pgp>


More information about the samba-technical mailing list