requires 'MooseX::Types' => '0.04';
requires 'Path::Class' => '0.16';
-# optional
-#feature 'MooseX::Getopt',
-# -default => 0,
-# 'MooseX::Getopt' => '0.05';
-#optional 'MooseX::Getopt' => 0.05;
-
# things the tests need
build_requires 'Test::More' => '0.62';
-auto_provides;
+#auto_provides;
#auto_install;
}
# optionally add Getopt option type
-use English qw(-no_match_vars);
eval { require MooseX::Getopt; };
-if ( !$EVAL_ERROR ) {
+if ( !$@ ) {
MooseX::Getopt::OptionTypeMap->add_option_type_to_map( $_, '=s', )
for ( 'Path::Class::Dir', 'Path::Class::File', Dir, File, );
}
the Getopt option type ("=s") will be added for both
L<Path::Class::Dir> and L<Path::Class::File>.
-This is just meant to be a central place for these constructs, so you
-don't have to worry about whether they've been created or not, and
-you're not tempted to copy them into yet another class (like I was).
-
=head1 EXPORTS
use warnings FATAL => 'all';
use strict;
-use English qw(-no_match_vars);
eval { require MooseX::Getopt; };
-if ($EVAL_ERROR) {
+if ($@) {
plan( skip_all => 'MooseX::Getopt required for this test' );
}
use strict;
use File::Spec;
use Test::More;
-use English qw(-no_match_vars);
if ( not $ENV{TEST_AUTHOR} ) {
my $msg
}
eval { require Test::Perl::Critic; };
-
-if ($EVAL_ERROR) {
+if ($@) {
my $msg = 'Test::Perl::Critic required to criticise code';
plan( skip_all => $msg );
}
use strict;
use Test::More;
eval "use Test::Pod::Coverage 1.04";
-if ($@) {
- plan skip_all =>
- "Test::Pod::Coverage 1.04 required for testing POD coverage";
-}
+plan skip_all =>
+ "Test::Pod::Coverage 1.04 required for testing POD coverage"
+ if ($@);
all_pod_coverage_ok();