Fix for LocalRegex when used in the Root controller
[catagits/Catalyst-Runtime.git] / t / lib / TestApp / Controller / Root.pm
index fc88317..53d79e2 100644 (file)
@@ -13,4 +13,11 @@ sub zero : Path('0') {
     $c->forward('TestApp::View::Dump::Request');
 }
 
+sub localregex : LocalRegex('^localregex$') {
+    my ( $self, $c ) = @_;
+    $c->res->header( 'X-Test-Class' => ref($self) );
+    $c->response->content_type('text/plain; charset=utf-8');
+    $c->forward('TestApp::View::Dump::Request');
+}
+
 1;