-d and --debug work for me
[catagits/Catalyst-Runtime.git] / t / TestApp / script / testapp_create.pl
index 8d6a4d2..16922aa 100755 (executable)
@@ -1,38 +1,12 @@
 #!/usr/bin/env perl
 
-use strict;
-use warnings;
-use Getopt::Long;
-use Pod::Usage;
-eval "use Catalyst::Helper;";
-
-if ($@) {
-  die <<END;
-To use the Catalyst development tools including catalyst.pl and the
-generated script/myapp_create.pl you need Catalyst::Helper, which is
-part of the Catalyst-Devel distribution. Please install this via a
-vendor package or by running one of -
-
-  perl -MCPAN -e 'install Catalyst::Devel'
-  perl -MCPANPLUS -e 'install Catalyst::Devel'
-END
-}
-
-my $force = 0;
-my $mech  = 0;
-my $help  = 0;
-
-GetOptions(
-    'nonew|force'    => \$force,
-    'mech|mechanize' => \$mech,
-    'help|?'         => \$help
- );
-
-pod2usage(1) if ( $help || !$ARGV[0] );
-
-my $helper = Catalyst::Helper->new( { '.newfiles' => !$force, mech => $mech } );
-
-pod2usage(1) unless $helper->mk_component( 'TestApp', @ARGV );
+use FindBin qw/$Bin/;
+
+## because this is a test
+use lib "$Bin/../../../lib";
+use Catalyst::ScriptRunner;
+Catalyst::ScriptRunner->run('TestApp','Create');
+
 
 1;