fix threads test.
[catagits/Catalyst-Runtime.git] / t / optional_threads.t
index 50a6ecd..4d9a18a 100644 (file)
@@ -10,6 +10,7 @@ use Test::More;
 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