| 1 | 1 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 2 | 1 | ▶ | use warnings; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 3 | package Dist::Zilla::Plugin::Test::Prereqs::Latest; | ||||||||||
| 4 | 1 | $Dist::Zilla::Plugin::Test::Prereqs::Latest::VERSION = '0.001'; # TRIAL | |||||||||
| 5 | # ABSTRACT: Tests your module has up to date dependencies | ||||||||||
| 6 | # VERSION | ||||||||||
| 7 | |||||||||||
| 8 | 1 | ▶ | use 5.008; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 9 | |||||||||||
| 10 | 1 | ▶ | use Moose; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 11 | 1 | extends 'Dist::Zilla::Plugin::InlineFiles'; | |||||||||
| 12 | 1 | with 'Dist::Zilla::Role::FilePruner'; | |||||||||
| 13 | |||||||||||
| 14 | =pod | ||||||||||
| 15 | |||||||||||
| 16 | =encoding UTF-8 | ||||||||||
| 17 | |||||||||||
| 18 | =head1 NAME | ||||||||||
| 19 | |||||||||||
| 20 | Dist::Zilla::Plugin::Test::Prereqs::Current - Dzil plugin to check prereqs are up to date | ||||||||||
| 21 | |||||||||||
| 22 | =head1 DESCRIPTION | ||||||||||
| 23 | |||||||||||
| 24 | Tests that the versions in the [Prereqs] setion of the dist.ini are up to date | ||||||||||
| 25 | |||||||||||
| 26 | =head1 SYNOPSIS | ||||||||||
| 27 | |||||||||||
| 28 | To be written. | ||||||||||
| 29 | |||||||||||
| 30 | =head1 SUBLASSES / INTERFACES / ATTRIBUTES | ||||||||||
| 31 | |||||||||||
| 32 | |||||||||||
| 33 | =head2 prune_files | ||||||||||
| 34 | |||||||||||
| 35 | Stub for docs | ||||||||||
| 36 | |||||||||||
| 37 | =head1 AUTHOR | ||||||||||
| 38 | |||||||||||
| 39 | Lance Wicks <lancew@cpan.org> | ||||||||||
| 40 | |||||||||||
| 41 | =head1 CONTRIBUTORS | ||||||||||
| 42 | |||||||||||
| 43 | =head1 COPYRIGHT | ||||||||||
| 44 | |||||||||||
| 45 | This software is Copyright (c) 2022 by Lance Wicks. | ||||||||||
| 46 | |||||||||||
| 47 | =head1 LICENSE | ||||||||||
| 48 | |||||||||||
| 49 | This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. | ||||||||||
| 50 | See the LICENSE file in the distribution on CPAN for full text. | ||||||||||
| 51 | |||||||||||
| 52 | =cut | ||||||||||
| 53 | |||||||||||
| 54 | sub prune_files | ||||||||||
| 55 | 0 | ▶ | { | ||||||||
|
Subroutine
prune_files: not called CC=2 SCAR=17.9
Pod
documented
| |||||||||||
| 56 | 0 | my $self = shift; | |||||||||
| 57 | |||||||||||
| 58 | 0 | my $files = $self->zilla->files; | |||||||||
| 59 | |||||||||||
| 60 | 0 | ▶ | unless (grep { $_->name eq 'dist.ini' } @$files) { | ||||||||
|
Branch: 1 branch
| |||||||||||
| 61 | 0 | $self->log("WARNING: dist.ini not found, removing xt/author/prereqs_latest.t"); | |||||||||
| 62 | 0 | @$files = grep { $_->name ne 'xt/author/prereqs_latest.t' } @$files; | |||||||||
| 63 | } # end unless META.json | ||||||||||
| 64 | |||||||||||
| 65 | 0 | return; | |||||||||
| 66 | } # end prune_files | ||||||||||
| 67 | |||||||||||
| 68 | 1 | ▶ | no Moose; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 69 | 1 | __PACKAGE__->meta->make_immutable; | |||||||||
| 70 | 1 | 1; | |||||||||
| 71 | __DATA__ | ||||||||||