develooper Front page | perl.perl5.porters | Postings from June 2013

[perl #118553] [PATCH] 0898b35 Benchmark.t: fix skip() argument order

Thread Next
From:
James E Keenan via RT
Date:
June 21, 2013 00:15
Subject:
[perl #118553] [PATCH] 0898b35 Benchmark.t: fix skip() argument order
Message ID:
rt-3.6.HEAD-2552-1371773707-1127.118553-15-0@perl.org
On Thu Jun 20 16:25:17 2013, gottreu wrote:
> 
> This is a bug report for perl from gottreu@gmail.com,
> generated with the help of perlbug 1.39 running under perl 5.19.1.
> 
> From 0898b35cfbe8d05e1db0eb210a87559dca58e537 Mon Sep 17 00:00:00 2001
> From: Brian Gottreu <gottreu@gmail.com>
> Date: Thu, 20 Jun 2013 18:09:55 -0500
> Subject: [PATCH] Benchmark.t: fix skip() argument order
> MIME-Version: 1.0
> Content-Type: multipart/mixed; boundary="------------1.7.10.4"
> 
> This is a multi-part message in MIME format.
> --------------1.7.10.4
> Content-Type: text/plain; charset=UTF-8; format=fixed
> Content-Transfer-Encoding: 8bit
> 
> ---
>  lib/Benchmark.t |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> 
> --------------1.7.10.4
> Content-Type: text/x-patch; name="0001-Benchmark.t-fix-skip-argument-
> order.patch"
> Content-Transfer-Encoding: 8bit
> Content-Disposition: attachment; filename="0001-Benchmark.t-fix-skip-
> argument-order.patch"
> 
> diff --git a/lib/Benchmark.t b/lib/Benchmark.t
> index b7d4e7c..1b8d4b4 100644
> --- a/lib/Benchmark.t
> +++ b/lib/Benchmark.t
> @@ -155,7 +155,7 @@ $in_onesec_adj *= (1/$cpu1); # adjust because may
> not have run for exactly 1s
>  print "# in_onesec_adj=$in_onesec_adj adjusted iterations\n";
> 
>  SKIP: {
> -    skip(1, "INCONSISTENT CLOCK") if $INCONSISTENT_CLOCK;
> +    skip("INCONSISTENT CLOCK", 1) if $INCONSISTENT_CLOCK;
> 
>      ok(cmp_delta($in_onesec_adj, $estimate, $DELTA),
>  		"is $in_onesec_adj within $DELTA of estimate ($estimate)?")
> 

I believe this bug report is correct -- which means that this was an
incorrect fix:

#####
$ git show 5c39bf19
commit 5c39bf1981fd94f2f7d0c551c307701ce0faeda6
Author: David Mitchell <davem@iabyn.com>
Date:   Thu Jun 13 09:00:56 2013 +0100

    Benchmark.t: fix skip() call

diff --git a/lib/Benchmark.t b/lib/Benchmark.t
index bb25cd8..b7d4e7c 100644
--- a/lib/Benchmark.t
+++ b/lib/Benchmark.t
@@ -155,7 +155,7 @@ $in_onesec_adj *= (1/$cpu1); # adjust because may
not have run for exactly 1s
 print "# in_onesec_adj=$in_onesec_adj adjusted iterations\n";
 
 SKIP: {
-    skip("INCONSISTENT CLOCK") if $INCONSISTENT_CLOCK;
+    skip(1, "INCONSISTENT CLOCK") if $INCONSISTENT_CLOCK;
 
     ok(cmp_delta($in_onesec_adj, $estimate, $DELTA),
                "is $in_onesec_adj within $DELTA of estimate ($estimate)?")
#####

Dave, can you please take a look?

Thank you very much.
Jim Keenan


---
via perlbug:  queue: perl5 status: new
https://rt.perl.org:443/rt3/Ticket/Display.html?id=118553

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About