stop using Moo as a test package
[catagits/Catalyst-Runtime.git] / t / lib / TestApp / View / Dump.pm
index 2699103..016df81 100644 (file)
@@ -18,7 +18,7 @@ sub dump {
     $dumper->Purity($purity);
     $dumper->Useqq(0);
     $dumper->Deepcopy(1);
-    $dumper->Quotekeys(0);
+    $dumper->Quotekeys(1);
     $dumper->Terse(1);
 
     local $SIG{ __WARN__ } = sub { warn unless $_[ 0 ] =~ m{dummy} };
@@ -39,6 +39,12 @@ sub process {
     # Remove context from reference if needed
     my $context = delete $reference->{_context};
 
+    my $env = delete $reference->{env};
+
+    if (my $log = $reference->{_log}) {
+        $log->clear_psgi if ($log->can('psgienv'));
+    }
+
     if ( my $output =
         $self->dump( $reference, $purity ) )
     {
@@ -58,6 +64,8 @@ sub process {
             $reference->{_body} = $body;
         }
 
+        if($env) { $reference->{env} = $env }
+
         return 1;
     }