view release on metacpan or search on metacpan
"version" : "0.006"
}
},
"name" : "@Author::ETHER/CheckSelfDependency",
"version" : "0.011"
},
{
"class" : "Dist::Zilla::Plugin::Run::AfterBuild",
"config" : {
"Dist::Zilla::Plugin::Run::Role::Runner" : {
"fatal_errors" : 1,
"quiet" : 1,
"run" : [
"bash -c \"test -e .ackrc && grep -q -- '--ignore-dir=.latest' .ackrc || echo '--ignore-dir=.latest' >> .ackrc; if [[ `dirname '%d'` != .build ]]; then test -e .ackrc && grep -q -- '--ignore-dir=%d' .ackrc || echo '--ignore-dir=%...
],
"version" : "0.048"
}
},
"name" : "@Author::ETHER/.ackrc",
"version" : "0.048"
},
{
"class" : "Dist::Zilla::Plugin::Run::AfterBuild",
"config" : {
"Dist::Zilla::Plugin::Run::Role::Runner" : {
"eval" : [
"if ('%d' =~ /^%n-[.[:xdigit:]]+$/) { unlink '.latest'; symlink '%d', '.latest'; }"
],
"fatal_errors" : 0,
"quiet" : 1,
"version" : "0.048"
}
},
"name" : "@Author::ETHER/.latest",
"version" : "0.048"
},
{
"class" : "Dist::Zilla::Plugin::CheckStrictVersion",
"name" : "@Author::ETHER/CheckStrictVersion",
"metacpan" : 1
}
},
"name" : "@Author::ETHER/GitHub::Update",
"version" : "0.47"
},
{
"class" : "Dist::Zilla::Plugin::Run::AfterRelease",
"config" : {
"Dist::Zilla::Plugin::Run::Role::Runner" : {
"fatal_errors" : 0,
"quiet" : 0,
"run" : [
"REDACTED"
],
"version" : "0.048"
}
},
"name" : "@Author::ETHER/install release",
"version" : "0.048"
},
{
"class" : "Dist::Zilla::Plugin::Run::AfterRelease",
"config" : {
"Dist::Zilla::Plugin::Run::Role::Runner" : {
"eval" : [
"print \"release complete!\\xa\""
],
"fatal_errors" : 1,
"quiet" : 1,
"version" : "0.048"
}
},
"name" : "@Author::ETHER/release complete",
"version" : "0.048"
},
{
"class" : "Dist::Zilla::Plugin::ConfirmRelease",
"name" : "@Author::ETHER/ConfirmRelease",
- ':InstallModules'
Dist::Zilla::Role::ModuleMetadata:
Module::Metadata: '1.000037'
version: '0.006'
name: '@Author::ETHER/CheckSelfDependency'
version: '0.011'
-
class: Dist::Zilla::Plugin::Run::AfterBuild
config:
Dist::Zilla::Plugin::Run::Role::Runner:
fatal_errors: 1
quiet: 1
run:
- "bash -c \"test -e .ackrc && grep -q -- '--ignore-dir=.latest' .ackrc || echo '--ignore-dir=.latest' >> .ackrc; if [[ `dirname '%d'` != .build ]]; then test -e .ackrc && grep -q -- '--ignore-dir=%d' .ackrc || echo '--ignore-dir=%d' >> ....
version: '0.048'
name: '@Author::ETHER/.ackrc'
version: '0.048'
-
class: Dist::Zilla::Plugin::Run::AfterBuild
config:
Dist::Zilla::Plugin::Run::Role::Runner:
eval:
- "if ('%d' =~ /^%n-[.[:xdigit:]]+$/) { unlink '.latest'; symlink '%d', '.latest'; }"
fatal_errors: 0
quiet: 1
version: '0.048'
name: '@Author::ETHER/.latest'
version: '0.048'
-
class: Dist::Zilla::Plugin::CheckStrictVersion
name: '@Author::ETHER/CheckStrictVersion'
version: '0.001'
-
class: Dist::Zilla::Plugin::CheckMetaResources
class: Dist::Zilla::Plugin::GitHub::Update
config:
Dist::Zilla::Plugin::GitHub::Update:
metacpan: 1
name: '@Author::ETHER/GitHub::Update'
version: '0.47'
-
class: Dist::Zilla::Plugin::Run::AfterRelease
config:
Dist::Zilla::Plugin::Run::Role::Runner:
fatal_errors: 0
quiet: 0
run:
- REDACTED
version: '0.048'
name: '@Author::ETHER/install release'
version: '0.048'
-
class: Dist::Zilla::Plugin::Run::AfterRelease
config:
Dist::Zilla::Plugin::Run::Role::Runner:
eval:
- 'print "release complete!\xa"'
fatal_errors: 1
quiet: 1
version: '0.048'
name: '@Author::ETHER/release complete'
version: '0.048'
-
class: Dist::Zilla::Plugin::ConfirmRelease
name: '@Author::ETHER/ConfirmRelease'
version: '6.014'
-
class: Dist::Zilla::Plugin::Prereqs
lib/Algorithm/Dependency.pm view on Meta::CPAN
#pod
#pod =item selected => [ 'A', 'B', 'C', etc... ]
#pod
#pod The C<selected> option provides a list of those items that have already been
#pod 'selected', acted upon, installed, or whatever. If another item depends on one
#pod in this list, we don't have to include it in the output of the C<schedule> or
#pod C<depends> methods.
#pod
#pod =item ignore_orphans => 1
#pod
#pod Normally, the item source is expected to be largely perfect and error free.
#pod An 'orphan' is an item name that appears as a dependency of another item, but
#pod doesn't exist, or has been deleted.
#pod
#pod By providing the C<ignore_orphans> flag, orphans are simply ignored. Without
#pod the C<ignore_orphans> flag, an error will be returned if an orphan is found.
#pod
#pod =back
#pod
#pod The C<new> constructor returns a new Algorithm::Dependency object on success,
#pod or C<undef> on error.
#pod
#pod =cut
sub new {
my $class = shift;
my %args = @_;
my $source = _INSTANCE($args{source}, 'Algorithm::Dependency::Source')
or return undef;
# Create the object
lib/Algorithm/Dependency.pm view on Meta::CPAN
#pod
#pod =cut
sub selected_list { sort keys %{$_[0]->{selected}} }
#pod =pod
#pod
#pod =head2 selected $name
#pod
#pod Given an item name, the C<selected> method will return true if the item is
#pod selected, false is not, or C<undef> if the item does not exist, or an error
#pod occurs.
#pod
#pod =cut
sub selected { $_[0]->{selected}->{$_[1]} }
#pod =pod
#pod
#pod =head2 item $name
#pod
lib/Algorithm/Dependency.pm view on Meta::CPAN
#pod items that also have to be selected to meet dependencies.
#pod
#pod That is, if item A depends on B and C then the C<depends> method would
#pod return a reference to an array with B and C. ( C<[ 'B', 'C' ]> )
#pod
#pod If multiple item names are provided, the same applies. The list returned
#pod will not contain duplicates.
#pod
#pod The method returns a reference to an array of item names on success, a
#pod reference to an empty array if no other items are needed, or C<undef>
#pod on error.
#pod
#pod NOTE: The result of C<depends> is ordered by an internal C<sort>
#pod irrespective of the ordering provided by the dependency handler. Use
#pod L<Algorithm::Dependency::Ordered> and C<schedule> to use the most
#pod common ordering (process sequence)
#pod
#pod =cut
sub depends {
my $self = shift;
lib/Algorithm/Dependency.pm view on Meta::CPAN
#pod dependencies, in the preferred order of action. For the normal algorithm,
#pod where order it not important, this is alphabetical order. This makes it
#pod easier for someone watching a program operate on the items to determine
#pod how far you are through the task and makes any logs easier to read.
#pod
#pod If any of the names you provided in the arguments is already selected, it
#pod will not be included in the list.
#pod
#pod The method returns a reference to an array of item names on success, a
#pod reference to an empty array if no items need to be acted upon, or C<undef>
#pod on error.
#pod
#pod =cut
sub schedule {
my $self = shift;
my @items = @_ or return undef;
# Get their dependencies
my $depends = $self->depends( @items ) or return undef;
lib/Algorithm/Dependency.pm view on Meta::CPAN
=item selected => [ 'A', 'B', 'C', etc... ]
The C<selected> option provides a list of those items that have already been
'selected', acted upon, installed, or whatever. If another item depends on one
in this list, we don't have to include it in the output of the C<schedule> or
C<depends> methods.
=item ignore_orphans => 1
Normally, the item source is expected to be largely perfect and error free.
An 'orphan' is an item name that appears as a dependency of another item, but
doesn't exist, or has been deleted.
By providing the C<ignore_orphans> flag, orphans are simply ignored. Without
the C<ignore_orphans> flag, an error will be returned if an orphan is found.
=back
The C<new> constructor returns a new Algorithm::Dependency object on success,
or C<undef> on error.
=head2 source
The C<source> method retrieves the L<Algorithm::Dependency::Source> object
for the algorithm context.
=head2 selected_list
The C<selected_list> method returns, as a list and in alphabetical order,
the list of the names of the selected items.
=head2 selected $name
Given an item name, the C<selected> method will return true if the item is
selected, false is not, or C<undef> if the item does not exist, or an error
occurs.
=head2 item $name
The C<item> method fetches and returns the item object, as specified by the
name argument.
Returns an L<Algorithm::Dependency::Item> object on success, or C<undef> if
an item does not exist for the argument provided.
lib/Algorithm/Dependency.pm view on Meta::CPAN
items that also have to be selected to meet dependencies.
That is, if item A depends on B and C then the C<depends> method would
return a reference to an array with B and C. ( C<[ 'B', 'C' ]> )
If multiple item names are provided, the same applies. The list returned
will not contain duplicates.
The method returns a reference to an array of item names on success, a
reference to an empty array if no other items are needed, or C<undef>
on error.
NOTE: The result of C<depends> is ordered by an internal C<sort>
irrespective of the ordering provided by the dependency handler. Use
L<Algorithm::Dependency::Ordered> and C<schedule> to use the most
common ordering (process sequence)
=head2 schedule $name1, ..., $nameN
Given a list of one or more item names, the C<depends> method will
return, as a reference to an array, the ordered list of items you
lib/Algorithm/Dependency.pm view on Meta::CPAN
dependencies, in the preferred order of action. For the normal algorithm,
where order it not important, this is alphabetical order. This makes it
easier for someone watching a program operate on the items to determine
how far you are through the task and makes any logs easier to read.
If any of the names you provided in the arguments is already selected, it
will not be included in the list.
The method returns a reference to an array of item names on success, a
reference to an empty array if no items need to be acted upon, or C<undef>
on error.
=head2 schedule_all;
The C<schedule_all> method acts the same as the C<schedule> method, but
returns a schedule that selected all the so-far unselected items.
=head1 TO DO
Add the C<check_source> method, to verify the integrity of the source.
lib/Algorithm/Dependency/Item.pm view on Meta::CPAN
#pod =pod
#pod
#pod =head2 new $id, @depends
#pod
#pod The C<new> constructor takes as its first argument the id ( name ) of the
#pod item, and any further arguments are assumed to be the ids of other items that
#pod this one depends on.
#pod
#pod Returns a new C<Algorithm::Dependency::Item> on success, or C<undef>
#pod on error.
#pod
#pod =cut
sub new {
my $class = shift;
my $id = (defined $_[0] and ! ref $_[0] and $_[0] ne '') ? shift : return undef;
bless { id => $id, depends => [ @_ ] }, $class;
}
#pod =pod
lib/Algorithm/Dependency/Item.pm view on Meta::CPAN
=head1 METHODS
=head2 new $id, @depends
The C<new> constructor takes as its first argument the id ( name ) of the
item, and any further arguments are assumed to be the ids of other items that
this one depends on.
Returns a new C<Algorithm::Dependency::Item> on success, or C<undef>
on error.
=head2 id
The C<id> method returns the id of the item.
=head2 depends
The C<depends> method returns, as a list, the names of the other items that
this item depends on.
lib/Algorithm/Dependency/Ordered.pm view on Meta::CPAN
# version, so we can simplify the algorithm greatly by using the
# normal unordered ->schedule method to get the starting list.
my $rv = $self->SUPER::schedule( @items );
my @queue = $rv ? @$rv : return undef;
# Get a working copy of the selected index
my %selected = %{ $self->{selected} };
# If at any time we check every item in the stack without finding
# a suitable candidate for addition to the schedule, we have found
# a circular reference error. We need to create a marker to track this.
my $error_marker = '';
# Begin the processing loop
my @schedule = ();
while ( my $id = shift @queue ) {
# Have we checked every item in the stack?
return undef if $id eq $error_marker;
# Are there any un-met dependencies
my $Item = $self->{source}->item($id) or return undef;
my @missing = grep { ! $selected{$_} } $Item->depends;
# Remove orphans if we are ignoring them
if ( $self->{ignore_orphans} ) {
@missing = grep { $self->{source}->item($_) } @missing;
}
if ( @missing ) {
# Set the error marker if not already
$error_marker = $id unless $error_marker;
# Add the id back to the end of the queue
push @queue, $id;
next;
}
# All dependencies have been met. Add the item to the schedule and
# to the selected index, and clear the error marker.
push @schedule, $id;
$selected{$id} = 1;
$error_marker = '';
}
# All items have been added
\@schedule;
}
1;
__END__
lib/Algorithm/Dependency/Source.pm view on Meta::CPAN
#pod
#pod Although you cannot directly use the C<new> constructor for
#pod C<Algorithm::Dependency::Source>, it will work the same in all subclasses.
#pod
#pod The constructor takes zero or more subclass specific arguments to define the
#pod location of the source of the items, and returns a new object. Although it
#pod may check that the arguments you passed are valid, the source will usually
#pod NOT actually load the items from the source, instead deferring the loading
#pod until you need to use the items.
#pod
#pod Returns a new object on success, or C<undef> on error.
#pod
#pod =cut
sub new {
my $class = shift;
# This can't be created directly, it must be through
# a SUPER::new call
if ( $class eq __PACKAGE__ ) {
die "Cannot directly instantiate Algorithm::Dependency::Source."
lib/Algorithm/Dependency/Source.pm view on Meta::CPAN
#pod =pod
#pod
#pod =head2 load
#pod
#pod The C<load> method is the public method used to actually load the items from
#pod their storage location into the the source object. The method will
#pod automatically called, as needed, in most circumstances. You would generally
#pod only want to use C<load> manually if you think there may be some uncertainty
#pod that the source will load correctly, and want to check it will work.
#pod
#pod Returns true if the items are loaded successfully, or C<undef> on error.
#pod
#pod =cut
sub load {
my $self = shift;
# If this is a reload, clean up in preperation
if ( $self->{loaded} ) {
$self->{loaded} = 0;
$self->{items_hash} = undef;
lib/Algorithm/Dependency/Source.pm view on Meta::CPAN
#pod =pod
#pod
#pod =head2 items
#pod
#pod The C<items> method returns, as a list of objects, all of the items
#pod contained in the source. The item objects will be returned in the same order
#pod as that in the storage location.
#pod
#pod Returns a list of L<Algorithm::Dependency::Item> objects on success, or
#pod C<undef> on error.
#pod
#pod =cut
sub items {
my $self = shift;
$self->{loaded} or $self->load or return undef;
@{ $self->{items_array} };
}
#pod =pod
#pod
#pod =head2 missing_dependencies
#pod
#pod By default, we are lenient with missing dependencies if the item is never
#pod used. For systems where having a missing dependency can be very bad, the
#pod C<missing_dependencies> method checks all Items to make sure their
#pod dependencies exist.
#pod
#pod If there are any missing dependencies, returns a reference to an array of
#pod their ids. If there are no missing dependencies, returns 0. Returns
#pod C<undef> on error.
#pod
#pod =cut
sub missing_dependencies {
my $self = shift;
$self->{loaded} or $self->load or return undef;
# Merged the depends of all the items, and see if
# any are missing.
my %missing = map { $_ => 1 }
lib/Algorithm/Dependency/Source.pm view on Meta::CPAN
Although you cannot directly use the C<new> constructor for
C<Algorithm::Dependency::Source>, it will work the same in all subclasses.
The constructor takes zero or more subclass specific arguments to define the
location of the source of the items, and returns a new object. Although it
may check that the arguments you passed are valid, the source will usually
NOT actually load the items from the source, instead deferring the loading
until you need to use the items.
Returns a new object on success, or C<undef> on error.
=head2 load
The C<load> method is the public method used to actually load the items from
their storage location into the the source object. The method will
automatically called, as needed, in most circumstances. You would generally
only want to use C<load> manually if you think there may be some uncertainty
that the source will load correctly, and want to check it will work.
Returns true if the items are loaded successfully, or C<undef> on error.
=head2 item $name
The C<item> method fetches and returns the item object specified by the
name argument.
Returns an L<Algorithm::Dependency::Item> object on success, or C<undef> if
the named item does not exist in the source.
=head2 items
The C<items> method returns, as a list of objects, all of the items
contained in the source. The item objects will be returned in the same order
as that in the storage location.
Returns a list of L<Algorithm::Dependency::Item> objects on success, or
C<undef> on error.
=head2 missing_dependencies
By default, we are lenient with missing dependencies if the item is never
used. For systems where having a missing dependency can be very bad, the
C<missing_dependencies> method checks all Items to make sure their
dependencies exist.
If there are any missing dependencies, returns a reference to an array of
their ids. If there are no missing dependencies, returns 0. Returns
C<undef> on error.
=head1 EXTENDING
C<Algorithm::Dependency::Source> itself is a fairly thin module, and it
is intended that you will probably need to extend it to be able to
extract item data from whatever location you have stored them.
This is usually a fairly simple two step process.
=over 4
=item Overload the C<new> method.
Assuming your subclass takes some form or argument on creation, you will
need to overload the C<new> method to accept the arguments, validate them,
and store them in the source object.
=item Define the method C<_load_item_list>.
Leaving our parent's C<load> method to take care of conflict, errors, and
whatever, the C<_load_item_list> method is used to simply create a list of
L<Algorithm::Dependency::Item> objects from wherever you store the item,
and return them as a list.
=back
Having completed these two things, your subclass should be completed. For
an example of the code, have a look at the source for the simple subclass
L<Algorithm::Dependency::Source::File>.
lib/Algorithm/Dependency/Weight.pm view on Meta::CPAN
#pod
#pod =item source => $Source
#pod
#pod The C<source> param is mostly the same as for L<Algorithm::Dependency>.
#pod The one addition is that as a source you can provide an
#pod L<Algorithm::Dependency> object, and the L<Algorithm::Dependency::Source>
#pod for that will be used.
#pod
#pod =back
#pod
#pod Returns a new C<Algorithm::Dependency::Weight> object, or C<undef> on error.
#pod
#pod =cut
sub new {
my $class = shift;
my %args = @_;
# Get the source object, or derive it from an existing alg-dep
my $source = _INSTANCE($args{source}, 'Algorithm::Dependency')
? $args{source}->source
lib/Algorithm/Dependency/Weight.pm view on Meta::CPAN
#pod =pod
#pod
#pod =head2 weight $name
#pod
#pod The C<weight> method takes the name of a single item and calculates its
#pod weight based on the configuration of the C<Algorithm::Dependency::Weight>
#pod object.
#pod
#pod Returns the weight as a scalar (which in the naive case will be an
#pod integer, but in more complex uses may be any real number), or C<undef>
#pod on error.
#pod
#pod =cut
sub weight {
my $self = shift;
my $id = defined(_STRING($_[0])) ? shift : return undef;
$self->{weight}->{$id} or
$self->{weight}->{$id} = $self->_weight($id);
}
lib/Algorithm/Dependency/Weight.pm view on Meta::CPAN
scalar(@$items);
}
#pod =pod
#pod
#pod =head2 weight_merged @names
#pod
#pod The C<weight_merged> method takes the name of a set of items and
#pod calculates an aggregated weight for the whole set.
#pod
#pod Returns the weight as a scalar, or C<undef> on error.
#pod
#pod =cut
sub weight_merged {
my $self = shift;
my $items = $self->{algdep}->schedule(@_) or return undef;
scalar(@$items);
}
#pod =pod
#pod
#pod =head2 weight_hash @names
#pod
#pod The C<weight_hash> method takes a list of item names, and calculates
#pod their weights.
#pod
#pod Returns a reference to a C<HASH> with the item names as keys and weights
#pod as values, or C<undef> on error.
#pod
#pod =cut
sub weight_hash {
my $self = shift;
my @names = @_;
# Iterate over the list
my %hash = ();
foreach my $name ( @names ) {
lib/Algorithm/Dependency/Weight.pm view on Meta::CPAN
#pod =pod
#pod
#pod =head2 weight_all
#pod
#pod The C<weight_all> method provides the one-shot method for getting the
#pod weights of all items at once. Please note that this does not do
#pod anything different or special, but is slightly faster than iterating
#pod yourself.
#pod
#pod Returns a reference to a C<HASH> with the item names as keys and weights
#pod as values, or C<undef> on error.
#pod
#pod =cut
sub weight_all {
my $self = shift;
my @items = $self->source->items;
defined $items[0] or return undef;
$self->weight_hash( map { $_->id } @items );
}
lib/Algorithm/Dependency/Weight.pm view on Meta::CPAN
=item source => $Source
The C<source> param is mostly the same as for L<Algorithm::Dependency>.
The one addition is that as a source you can provide an
L<Algorithm::Dependency> object, and the L<Algorithm::Dependency::Source>
for that will be used.
=back
Returns a new C<Algorithm::Dependency::Weight> object, or C<undef> on error.
=head2 source
The C<source> accessor returns the source used for the weight calculations.
This will be either the one passed to the constructor, or the source from
inside the C<Algorithm::Dependency> object passed as the C<source> param
(B<not> the object itself, B<its> source).
=head2 weight $name
The C<weight> method takes the name of a single item and calculates its
weight based on the configuration of the C<Algorithm::Dependency::Weight>
object.
Returns the weight as a scalar (which in the naive case will be an
integer, but in more complex uses may be any real number), or C<undef>
on error.
=head2 weight_merged @names
The C<weight_merged> method takes the name of a set of items and
calculates an aggregated weight for the whole set.
Returns the weight as a scalar, or C<undef> on error.
=head2 weight_hash @names
The C<weight_hash> method takes a list of item names, and calculates
their weights.
Returns a reference to a C<HASH> with the item names as keys and weights
as values, or C<undef> on error.
=head2 weight_all
The C<weight_all> method provides the one-shot method for getting the
weights of all items at once. Please note that this does not do
anything different or special, but is slightly faster than iterating
yourself.
Returns a reference to a C<HASH> with the item names as keys and weights
as values, or C<undef> on error.
=head1 TO DO
- Add support for non-naive weights via either custom code or method name
=head1 SEE ALSO
L<Algorithm::Dependency>, L<Algorithm::Dependency::Source>
=head1 SUPPORT
t/00-report-prereqs.t view on Meta::CPAN
my $static_prereqs = do './t/00-report-prereqs.dd';
# Merge all prereqs (either with ::Prereqs or a hashref)
my $full_prereqs = _merge_prereqs(
( $HAS_CPAN_META ? $cpan_meta_pre->new : {} ),
$static_prereqs
);
# Add dynamic prereqs to the included modules list (if we can)
my ($source) = grep { -f } 'MYMETA.json', 'MYMETA.yml';
my $cpan_meta_error;
if ( $source && $HAS_CPAN_META
&& (my $meta = eval { CPAN::Meta->load_file($source) } )
) {
$full_prereqs = _merge_prereqs($full_prereqs, $meta->prereqs);
}
else {
$cpan_meta_error = $@; # capture error from CPAN::Meta->load_file($source)
$source = 'static metadata';
}
my @full_reports;
my @dep_errors;
my $req_hash = $HAS_CPAN_META ? $full_prereqs->as_string_hash : $full_prereqs;
# Add static includes into a fake section
for my $mod (@include) {
$req_hash->{other}{modules}{$mod} = 0;
}
for my $phase ( qw(configure build test runtime develop other) ) {
next unless $req_hash->{$phase};
next if ($phase eq 'develop' and not $ENV{AUTHOR_TESTING});
t/00-report-prereqs.t view on Meta::CPAN
my $req_string = $want eq 'any' ? 'any version required' : "version '$want' required";
if ($prefix) {
my $have = MM->parse_version( File::Spec->catfile($prefix, $file) );
$have = "undef" unless defined $have;
push @reports, [$mod, $want, $have];
if ( $DO_VERIFY_PREREQS && $HAS_CPAN_META && $type eq 'requires' ) {
if ( $have !~ /\A$lax_version_re\z/ ) {
push @dep_errors, "$mod version '$have' cannot be parsed ($req_string)";
}
elsif ( ! $full_prereqs->requirements_for( $phase, $type )->accepts_module( $mod => $have ) ) {
push @dep_errors, "$mod version '$have' is not in required range '$want'";
}
}
}
else {
push @reports, [$mod, $want, "missing"];
if ( $DO_VERIFY_PREREQS && $type eq 'requires' ) {
push @dep_errors, "$mod is not installed ($req_string)";
}
}
}
if ( @reports ) {
push @full_reports, "=== $title ===\n\n";
my $ml = _max( map { length $_->[0] } @reports );
my $wl = _max( map { length $_->[1] } @reports );
my $hl = _max( map { length $_->[2] } @reports );
t/00-report-prereqs.t view on Meta::CPAN
push @full_reports, "\n";
}
}
}
if ( @full_reports ) {
diag "\nVersions for all modules listed in $source (including optional ones):\n\n", @full_reports;
}
if ( $cpan_meta_error || @dep_errors ) {
diag "\n*** WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING ***\n";
}
if ( $cpan_meta_error ) {
my ($orig_source) = grep { -f } 'MYMETA.json', 'MYMETA.yml';
diag "\nCPAN::Meta->load_file('$orig_source') failed with: $cpan_meta_error\n";
}
if ( @dep_errors ) {
diag join("\n",
"\nThe following REQUIRED prerequisites were not satisfied:\n",
@dep_errors,
"\n"
);
}
pass;
# vim: ts=4 sts=4 sw=4 et:
t/06_ignore_orphans.t view on Meta::CPAN
# Check that errors are correctly ignored when the 'ignore_orphans' option
# is turned on.
use strict;
BEGIN {
$| = 1;
$^W = 1;
}
use Test::More tests => 11;
use File::Spec::Functions ':ALL';