use System::Introspector::Config;
+require 't/logsetup.pl';
+
my $config = System::Introspector::Config->new(
config_file => "$FindBin::Bin/data/test.conf",
);
use System::Introspector::Probe::DiskUsage;
+require 't/logsetup.pl';
+
my $probe = System::Introspector::Probe::DiskUsage->new;
my $result = $probe->gather;
use System::Introspector::Probe::FileHandles;
+require 't/logsetup.pl';
+
$ENV{PATH} = "$FindBin::Bin/bin:" . $ENV{PATH};
my $probe = System::Introspector::Probe::FileHandles->new;
use System::Introspector::Probe::Groups;
+require 't/logsetup.pl';
+
my $probe = System::Introspector::Probe::Groups->new;
my $result = $probe->gather;
use System::Introspector::Probe::Host;
+require 't/logsetup.pl';
+
my $probe = System::Introspector::Probe::Host->new(
hostname_file => "$FindBin::Bin/data/hostname",
);
use System::Introspector::Probe::Hosts;
+require 't/logsetup.pl';
+
my $probe = System::Introspector::Probe::Hosts->new(
hosts_file => "$FindBin::Bin/data/hosts",
);
use System::Introspector::Probe::LibDirs::Perl;
+require 't/logsetup.pl';
+
my $dir = "$FindBin::Bin/data/libdir/perl";
no warnings 'redefine';
--- /dev/null
+#require this in the test to initialize the logging framewor
+#so the tests can run
+use System::Introspector::Logger qw( );
+System::Introspector::Logger->init_logging('WARN');
+1;
\ No newline at end of file
use System::Introspector::Probe::MountPoints;
+require 't/logsetup.pl';
+
my $probe = System::Introspector::Probe::MountPoints->new;
my $data = $probe->gather;
use System::Introspector::Probe::Nagios::CheckMkAgent;
+require 't/logsetup.pl';
+
no warnings 'redefine';
*System::Introspector::Probe::Nagios::CheckMkAgent::_get_check_mk_agent_output = sub {
return map "$_\n",
use System::Introspector::Probe::Packages::Apt;
+require 't/logsetup.pl';
+
my $probe = System::Introspector::Probe::Packages::Apt->new;
my $data = $probe->gather;
use System::Introspector::Probe::Perls;
+require 't/logsetup.pl';
+
do {
no warnings 'redefine';
*System::Introspector::Probe::Perls::_find_possible_perl_configs = sub {
use System::Introspector::Probe::Processes;
+require 't/logsetup.pl';
+
my $probe = System::Introspector::Probe::Processes->new;
my $result = $probe->gather;
use System::Introspector::Probe::Puppet;
+require 't/logsetup.pl';
+
my $probe = System::Introspector::Probe::Puppet->new(
classes_file => "$FindBin::Bin/data/puppet/classes.txt",
resources_file => "$FindBin::Bin/data/puppet/resources.txt",
use System::Introspector::Probe::Repositories::Git;
+require 't/logsetup.pl';
+
plan skip_all => q{Tests require a git executable}
unless `which git`;
use System::Introspector::Probe::ResolvConf;
+require 't/logsetup.pl';
+
my $probe = System::Introspector::Probe::ResolvConf->new(
resolv_conf_file => "$FindBin::Bin/data/resolv.conf",
);
use System::Introspector::Probe::Sudoers;
+require 't/logsetup.pl';
+
my $dir = "$FindBin::Bin/sudoers-data";
system("mkdir $dir");
use System::Introspector::Probe::Users;
+require 't/logsetup.pl';
+
my $passwd_file = "$FindBin::Bin/test-passwd";
my $home = "$FindBin::Bin/data/home-testfoo";
my $nohome = "$FindBin::Bin/data/home-doesnotexist";