Skip to content

Commit

Permalink
Fix running tests with Perl on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
Blackhex committed Dec 8, 2023
1 parent 8af227c commit 6058d9d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion configdata.pm.in
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ unless (caller) {
use Pod::Usage;

use lib '{- sourcedir('util', 'perl') -}';
use OpenSSL::fallback '{- sourcefile('external', 'perl', 'MODULES.txt') -}';
use OpenSSL::fallback;

my $here = dirname($0);

Expand Down
4 changes: 3 additions & 1 deletion test/run_tests.pl
Original file line number Diff line number Diff line change
Expand Up @@ -272,9 +272,11 @@ sub find_matching_tests {
return bless { %args }, $class;
}

sub runtests {
sub runtests {
my $self = shift;

print $self

# Pre TAP::Harness Test::Harness doesn't support [ filename, name ]
# elements, so convert such elements to just be the filename
my @args = map { ref($_) eq 'ARRAY' ? $_->[0] : $_ } @_;
Expand Down
7 changes: 1 addition & 6 deletions util/wrap.pl.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,7 @@ use File::Spec::Functions;
BEGIN {
# This method corresponds exactly to 'use OpenSSL::Util',
# but allows us to use a platform specific file spec.
require {-
use Cwd qw(abs_path);

"'" . abs_path(catfile($config{sourcedir},
'util', 'perl', 'OpenSSL', 'Util.pm')) . "'";
-};
require "$ENV{SRCTOP}/util/perl/OpenSSL/Util.pm";
OpenSSL::Util->import();
}

Expand Down

0 comments on commit 6058d9d

Please sign in to comment.