- Tweaked the error tests to handle more verbose error output
[catagits/Catalyst-Runtime.git] / t / lib / Catalyst / Plugin / Test / Errors.pm
index 4dc0d57..92fa63c 100644 (file)
@@ -21,7 +21,10 @@ sub error {
         $c->response->status(500);
     }
 
-    $c->response->headers->push_header( 'X-Catalyst-Error' => $_[0] );
+    my $error = $_[0];
+    $error =~ s/\n/, /g;
+
+    $c->response->headers->push_header( 'X-Catalyst-Error' => $error );
 
     $c->NEXT::error(@_);
 }