File: 00-load_all.t

package info (click to toggle)
parcimonie 0.11.0-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 500 kB
  • sloc: perl: 1,303; makefile: 82
file content (27 lines) | stat: -rw-r--r-- 659 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
use Test::Most;

use strictures 2;
use Path::Tiny;
use Module::Pluggable::Object;
eval { require Win32; };

# progs
# my @progs=path("bin", "parcimonie");
# foreach my $file (@progs) {
#         ok(system("perl -c $file") eq 0, $file);
# }

# libs
my @needsX = qw{App::Parcimonie::Applet};
my $finder = Module::Pluggable::Object->new(
               search_path => [ 'App::Parcimonie' ],
             );
foreach my $class (grep !/\.ToDo/,
                   sort do { local @INC = ('lib'); $finder->plugins }) {
  if (grep { $_ eq $class } @needsX) {
      next unless defined($ENV{DISPLAY}) && length($ENV{DISPLAY});
  }
  use_ok($class);
}

done_testing();