Skip Menu |

This queue is for tickets about the Test-HTTP-Response CPAN distribution.

Report information
The Basics
Id: 81644
Status: resolved
Worked: 1.3 hours (80 min)
Priority: 0/
Queue: Test-HTTP-Response

People
Owner: TEEJAY [...] cpan.org
Requestors: ANDK [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.04
Fixed in: 0.05



Subject: Test failures due to hash randomisation in perl 5.17.6
Since bleadperl v5.17.5-518-g7dc8663 your tests are failing frequently. That commit introduced hash key randomization and it seems at least the test t/03_headers.t is hit by that. Find a sample fail report at: http://www.cpantesters.org/cpan/report/37d52e60-31db-11e2-a41c-60a7a290f8f5 You can read more about the change at http://perl5.git.perl.org/perl.git/commit/7dc8663964c66a698d31bbdc8e8abed69bddeec3 or at http://www.perlmonks.org/?node_id=1005122 You may have to run the test several times until the randomization causes a fail. HTH&&Thanks&&Regards,
On Sun Dec 02 07:41:24 2012, ANDK wrote: Show quoted text
> Since bleadperl v5.17.5-518-g7dc8663 your tests are failing > frequently. > That commit introduced hash key randomization and it seems at least > the test > > t/03_headers.t > > is hit by that. Find a sample fail report at:
I spent an hour looking at the code last night and can't find anywhere that I'd expect it to be affected in the code itself, I suspect it may be one of the upstream modules giving unexpected results - will have to check if they have similar bug reports :(
CC: ANDK [...] cpan.org
Subject: Re: [rt.cpan.org #81644] Test failures due to hash randomisation in perl 5.17.6
Date: Fri, 04 Jan 2013 10:07:08 +0100
To: bug-Test-HTTP-Response [...] rt.cpan.org
From: Andreas Koenig <andreas.koenig.7os6VVqR [...] franz.ak.mind.de>
"Aaron James Trevena via RT" <bug-Test-HTTP-Response@rt.cpan.org> writes: Show quoted text
> I spent an hour looking at the code last night and can't find anywhere > that I'd expect it to be affected in the code itself, I suspect it may > be one of the upstream modules giving unexpected results - will have to > check if they have similar bug reports :(
In case it helps you to find the truth faster, here is the output from the debugger immediately before test 14 of 03_headers.t fails. You see that the oder of lines one and two is swapped. DB<5> c 337 Test::Builder::Tester::test_test(/home/src/perl/repoperls/installed-perls/perl/v5.17.7.0-195-g5398666/165a/lib/5.17.8/Test/Builder/Tester.pm:337): 337: unless( $t->ok( ( $args{skip_out} || $out->check ) && 338: ( $args{skip_err} || $err->check ), $mess ) 339: ) 340: { DB<6> x $out 0 Test::Builder::Tester::Tie=HASH(0x2a6e680) 'got' => 'ok 1 - HTTP header field content-Type matches ok 2 - HTTP header field Cache-control matches not ok 3 - Test for HTTP header field \'x-foo\' not ok 4 - Tests for all HTTP header fields ' 'type' => 'STDOUT' 'wanted' => ARRAY(0x30cbc70) 0 'ok 1 - HTTP header field Cache-control matches ok 2 - HTTP header field content-Type matches not ok 3 - Test for HTTP header field \'x-foo\' not ok 4 - Tests for all HTTP header fields ' -- andreas
Subject: Re: [rt.cpan.org #81644] Test failures due to hash randomisation in perl 5.17.6
Date: Fri, 4 Jan 2013 09:19:22 +0000
To: bug-Test-HTTP-Response [...] rt.cpan.org
From: Aaron Trevena <aaron.trevena [...] gmail.com>
On 4 January 2013 09:07, (Andreas J. Koenig) via RT <bug-Test-HTTP-Response@rt.cpan.org> wrote: Show quoted text
> Queue: Test-HTTP-Response > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=81644 > > > "Aaron James Trevena via RT" <bug-Test-HTTP-Response@rt.cpan.org> > writes: >
>> I spent an hour looking at the code last night and can't find anywhere >> that I'd expect it to be affected in the code itself, I suspect it may >> be one of the upstream modules giving unexpected results - will have to >> check if they have similar bug reports :(
> > In case it helps you to find the truth faster, here is the output from > the debugger immediately before test 14 of 03_headers.t fails. You see > that the oder of lines one and two is swapped.
Ah - will look again - thanks A -- Aaron J Trevena, BSc Hons http://www.aarontrevena.co.uk LAMP System Integration, Development and Consulting
D'oh spotted the brainfart - must have been pretty tired to miss that - sorting hash keys to ensure output test results always in same order should resolve problem - see https://github.com/hashbangperl/Test--HTTP--Response/commit/0b2c843cf75b08783b277e61569d36cc3036a35f which has been uploaded to CPAN as v0.05