new diagnostic
This commit is contained in:
1 parent
e955bb151a
commit
3ca192cd4f
4 files changed
+80
-3
No files matched your search
@@ -1,11 +1,13 @@
|
|||||||
use strict;
|
use strict;
|
||||||
use warnings;
|
use warnings;
|
||||||
use Test::More tests => 1;
|
use Test::More;
|
||||||
use Mojo::IOLoop;
|
use Mojo::IOLoop;
|
||||||
|
|
||||||
|
our $format;
|
||||||
|
|
||||||
my $loop = eval { Mojo::IOLoop->singleton };
|
my $loop = eval { Mojo::IOLoop->singleton };
|
||||||
diag $@ if $@;
|
diag $@ if $@;
|
||||||
ok $loop;
|
diag sprintf $format, 'mojo io loop', ref eval { $loop->reactor };
|
||||||
diag ref eval { $loop->reactor };
|
|
||||||
diag $@ if $@;
|
diag $@ if $@;
|
||||||
|
|
||||||
|
1;
|
||||||
+51
@@ -0,0 +1,51 @@
|
|||||||
|
use strict;
|
||||||
|
use warnings;
|
||||||
|
use Test::More tests => 1;
|
||||||
|
BEGIN { eval q{ use EV } }
|
||||||
|
eval q{
|
||||||
|
use FindBin ();
|
||||||
|
use File::Spec;
|
||||||
|
1;
|
||||||
|
} || die $@;
|
||||||
|
|
||||||
|
pass 'okay';
|
||||||
|
|
||||||
|
my @modules;
|
||||||
|
do {
|
||||||
|
my $fh;
|
||||||
|
open($fh, '<', File::Spec->catfile($FindBin::Bin, '00_diag.txt'));
|
||||||
|
@modules = <$fh>;
|
||||||
|
close $fh;
|
||||||
|
chomp @modules;
|
||||||
|
};
|
||||||
|
|
||||||
|
my $max = 1;
|
||||||
|
$max = $_ > $max ? $_ : $max for map { length $_ } @modules;
|
||||||
|
our $format = "%-${max}s %s";
|
||||||
|
|
||||||
|
diag '';
|
||||||
|
diag '';
|
||||||
|
diag '';
|
||||||
|
|
||||||
|
diag sprintf $format, 'perl ', $^V;
|
||||||
|
|
||||||
|
require(File::Spec->catfile($FindBin::Bin, '00_diag.pl'))
|
||||||
|
if -e File::Spec->catfile($FindBin::Bin, '00_diag.pl');
|
||||||
|
|
||||||
|
foreach my $module (@modules)
|
||||||
|
{
|
||||||
|
if(eval qq{ use $module; 1 })
|
||||||
|
{
|
||||||
|
my $ver = eval qq{ \$$module\::VERSION };
|
||||||
|
$ver = 'undef' unless defined $ver;
|
||||||
|
diag sprintf $format, $module, $ver;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
diag sprintf $format, $module, '-';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
diag '';
|
||||||
|
diag '';
|
||||||
|
diag '';
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
Carp
|
||||||
|
Cwd
|
||||||
|
EV
|
||||||
|
ExtUtils::MakeMaker
|
||||||
|
File::Spec
|
||||||
|
File::Temp
|
||||||
|
FindBin
|
||||||
|
IO::Handle
|
||||||
|
IPC::Open3
|
||||||
|
Mojo::Base
|
||||||
|
Mojo::ByteStream
|
||||||
|
Mojo::IOLoop
|
||||||
|
Mojolicious
|
||||||
|
Mojolicious::Lite
|
||||||
|
Mojolicious::Plugin
|
||||||
|
POSIX
|
||||||
|
Scalar::Util
|
||||||
|
Template
|
||||||
|
Template::Provider
|
||||||
|
Test::CPAN::Meta
|
||||||
|
Test::Mojo
|
||||||
|
Test::More
|
||||||
|
lib
|
||||||
|
utf8
|
||||||
File renamed without changes.
Reference in new issue
Block a user