diff --git a/contrib/windows/glpi-agent-built-perl-tests.pl b/contrib/windows/glpi-agent-built-perl-tests.pl index dd0b64d85..4607fb232 100644 --- a/contrib/windows/glpi-agent-built-perl-tests.pl +++ b/contrib/windows/glpi-agent-built-perl-tests.pl @@ -77,7 +77,7 @@ sub run { # Update PATH to include perl/bin for DLLs loading my $binpath = catfile($self->global->{image_dir}, 'perl/bin'); - $ENV{PATH} .= ":$binpath"; + $ENV{PATH} = "$binpath:$ENV{PATH}"; # Without defined modules, run the tests my $perlbin = catfile($binpath, 'perl.exe'); @@ -106,7 +106,7 @@ sub test { # Update PATH to include perl/bin for DLLs loading my $binpath = catfile($self->global->{image_dir}, 'perl/bin'); - $ENV{PATH} .= ":$binpath"; + $ENV{PATH} = "$binpath:$ENV{PATH}"; # Without defined modules, run the tests my $makebin = catfile($binpath, 'gmake.exe'); @@ -247,8 +247,7 @@ sub load_jobfile { plugin => 'Perl::Dist::GLPI::Agent::Step::Test', # By default all possible test will be run test_files => [ - #~ qw(t/*.t t/*/*.t t/*/*/*.t t/*/*/*/*.t t/*/*/*/*/*.t t/*/*/*/*/*/*.t) - qw(t/*.t) + qw(t/*.t t/*/*.t t/*/*/*.t t/*/*/*/*.t t/*/*/*/*/*.t t/*/*/*/*/*/*.t) ], skip_tests => [ # Fails if not run as administrator diff --git a/t/agent/config.t b/t/agent/config.t index d24006111..0bcbbc35f 100755 --- a/t/agent/config.t +++ b/t/agent/config.t @@ -167,6 +167,7 @@ ok (scalar(@{$c->{'httpd-trust'}}) == 4); SKIP: { skip ('test for Windows only', 7) if ($OSNAME ne 'MSWin32'); + skip ('registry access can only be tested as admin', 7) if system("net session 2>nul"); my $settings = GLPI::Test::Utils::openWin32Registry(); ok (defined $settings); my $testValue = time;