stop using Moo as a test package
[catagits/Catalyst-Runtime.git] / t / aggregate / unit_core_script_help.t
index d3a6fab..e2fc4a2 100644 (file)
@@ -1,8 +1,7 @@
-#!/usr/bin/env perl
 use strict;
 use warnings;
 use Test::More;
-use Test::Exception;
+use Test::Fatal;
 
 use FindBin qw/$Bin/;
 use lib "$Bin/../lib";
@@ -12,7 +11,7 @@ use lib "$Bin/../lib";
     use Moose;
     with 'Catalyst::ScriptRole';
     our $help;
-    sub _getopt_full_usage { $help++ }
+    sub print_usage_text { $help++ }
 }
 
 test('--help');
@@ -21,9 +20,9 @@ test('-?');
 sub test {
     local $TestHelpScript::help;
     local @ARGV = (@_);
-    lives_ok {
+    is exception {
         TestHelpScript->new_with_options(application_name => 'TestAppToTestScripts')->run;
-    } 'Lives';
+    }, undef, 'Lives';
     ok $TestHelpScript::help, 'Got help';
 }