Skip Menu |

This queue is for tickets about the Tie-RefHash CPAN distribution.

Report information
The Basics
Id: 32384
Status: resolved
Priority: 0/
Queue: Tie-RefHash

People
Owner: Nobody in particular
Requestors: jdhedden [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 1.38
Fixed in: (no value)



Subject: Not detecting threaded builds in tests
'make test' incorrectly skips tests for threaded builds: /usr/bin/perl.exe "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/rebless.......ok t/refhash.......ok t/storable......ok t/threaded......skipped: -- threads aren't enabled in your perl, or Scalar::Util::weaken is missing All tests successful. Files=4, Tests=65, 1 wallclock secs ( 0.06 usr 0.03 sys + 0.84 cusr 0.20 csys = 1.13 CPU) Result: PASS This is caused by the eval relying on the return value of threads->import which is not guaranteed to be true. The attached patch fixes this.
Subject: tr.patch
--- t/threaded.t.orig 2008-01-17 09:32:15.676853400 -0500 +++ t/threaded.t 2008-01-17 09:42:40.639465800 -0500 @@ -21,7 +21,7 @@ } if ( $Config{usethreads} and !$Config{use5005threads} and defined(&Scalar::Util::weaken) - and eval { require threads; "threads"->import } + and eval { require threads; threads->import; 1 } ) { print "1..14\n"; } else {
Thanks, applied in http://nothingmuch.woobling.org/browse_code?r=Tie- RefHash;a=commit;h=20080121015221-690ea- eb5e8d9118b38597c39a6f09b026809ff0fb1d02.gz I will delay release for now though