X-Git-Url: http://git.vpit.fr/?p=perl%2Fmodules%2FScope-Upper.git;a=blobdiff_plain;f=t%2F79-uid-threads.t;h=81321c1193a46ca476bdf359d6f261fcd614ec16;hp=8fe180deb2e29239de00d8ed5b8a0e2ae9ef53e6;hb=c6120af4f7a3990cebfdd10df0523832f560abd3;hpb=bac2d3bafef497b0c64e294795a9e6605fcb6422 diff --git a/t/79-uid-threads.t b/t/79-uid-threads.t index 8fe180d..81321c1 100644 --- a/t/79-uid-threads.t +++ b/t/79-uid-threads.t @@ -1,18 +1,18 @@ -#!perl -T +#!perl use strict; use warnings; -use Scope::Upper qw; - use lib 't/lib'; use VPIT::TestHelpers ( - threads => [ 'Scope::Upper' => Scope::Upper::SU_THREADSAFE ], + threads => [ 'Scope::Upper' => 'Scope::Upper::SU_THREADSAFE()' ], 'usleep', ); use Test::Leaner; +use Scope::Upper qw; + my $top = uid; sub cb { @@ -27,7 +27,7 @@ sub cb { is uid(UP), $top, "uid(UP) == \$top (in thread $tid)"; - usleep rand(1e6); + usleep rand(2.5e5); ok validate_uid($here), "\$here is valid (in thread $tid)"; ok !validate_uid($up), "\$up is no longer valid (in thread $tid)";