fix threads test.
[catagits/Catalyst-Runtime.git] / t / optional_threads.t
index 82c748a..4d9a18a 100644 (file)
@@ -4,12 +4,13 @@ use strict;
 use warnings;\r
 \r
 use FindBin;\r
-use lib "$FindBin::Bin/../live/lib";\r
+use lib "$FindBin::Bin/lib";\r
 \r
 use Test::More;\r
 use Catalyst::Test 'TestApp';\r
 use Catalyst::Request;\r
 use Config;\r
+use HTTP::Response;\r
 \r
 plan skip_all => 'set TEST_THREADS to enable this test'\r
     unless $ENV{TEST_THREADS};\r
@@ -30,7 +31,7 @@ else {
 no warnings 'redefine';\r
 sub request {\r
     my $thr = threads->new( \r
-        sub { TestApp->run(@_) },\r
+        sub { Catalyst::Test::local_request('TestApp',@_) },\r
         @_ \r
     );\r
     $thr->join;\r