Debian Codegraph @

xt/92-critic.t

raw
1 # test for recommendations from "Perl Best Practices"
2
3 use strict;
4 use warnings;
5 use Test::More;
6
7 eval {
8 require Test::Perl::Critic;
9 Test::Perl::Critic->import();
10 require Perl::Critic::Utils;
11 1;
12 } or plan skip_all => 'Test::Perl::Critic required';
13
14 # check only new code
15 my @dirs = qw( lib );
16 my @files = glob('t/*.t xt/*.t');
17
18 push @files, Perl::Critic::Utils::all_perl_files(@dirs);
19
20 plan tests => scalar(@files);
21 critic_ok($_) foreach @files;