fix for ext/threads/t/problems.t failures
[p5sagit/p5-mst-13.2.git] / ext / threads / t / end.t
index 199ca47..19cd704 100644 (file)
@@ -1,7 +1,10 @@
 
+# test that END blocks are run in the thread that created them and
+# not in any child threads
+
 BEGIN {
     chdir 't' if -d 't';
-    @INC = '../lib';
+    push @INC, '../lib';
     require Config; import Config;
     unless ($Config{'useithreads'}) {
         print "1..0 # Skip: no useithreads\n";
@@ -29,7 +32,7 @@ sub ok {
     $test_id++;
     return $ok;
 }
-ok(1);
+ok(1,'');
 END { ok(1,"End block run once") }
 threads->create(sub { eval "END { ok(1,'') }"})->join();
 threads->create(sub { eval "END { ok(1,'') }"})->join();