FURTHER QUESTIONS?
Check the list of additional DBIC resources.
COPYRIGHT AND LICENSE
This module is free software copyright by the DBIx::Class (DBIC) authors. You can redistribute it and/or modify it under the same terms as the DBIx::Class library. };
find({ wanted => sub { my $fn = $_;
return unless -f $fn;
return unless $fn =~ / \. (?: pm | pod ) $ /ix;
my $data = do { local (@ARGV, $/) = $fn; <> };
if ($data !~ /^=head1 NAME/m) {
# the generator is full of false positives, .pod is where it's at
return if $fn =~ qr{\Qlib/DBIx/Class/Optional/Dependencies.pm};
ok ( $data !~ /\bcopyright\b/i, "No copyright notices in $fn without apparent POD" );
}
elsif ($fn =~ qr{\Qlib/DBIx/Class.}) {
# nothing to check there - a static set of words
}
else {
ok ( $data !~ / ^ =head1 \s $_ /xmi, "No standalone $_ headings in $fn" )
for qw(AUTHOR CONTRIBUTOR LICENSE LICENCE);
ok ( $data !~ / ^ =head1 \s COPYRIGHT \s (?! AND \s LICENSE )/xmi, "No standalone COPYRIGHT headings in $fn" );
ok ($data =~ / \Q$boilerplate_headings\E (?! .*? ^ =head )/xms, "Expected headings found at the end of $fn");
}
},
no_chdir => 1,
}, (qw(lib examples)) );
done_testing;