Skip to content

Commit ce89847

Browse files
committed
Finalize unit test
* pattern search + replace for tls_sockets() vs. openssl * better error handling for invocations with perl functions system + die
1 parent cbaa813 commit ce89847

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

t/12_diff_opensslversions.t

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ my $cat_csvfile2="";
1919
my $uri="google.com";
2020
my $diff="";
2121
my $distro_openssl="/usr/bin/openssl";
22+
my @args="";
2223

2324
die "Unable to open $prg" unless -f $prg;
2425
die "Unable to open $distro_openssl" unless -f $distro_openssl;
@@ -29,11 +30,15 @@ unlink "tmp2.csv";
2930

3031
#1 run
3132
printf "\n%s\n", "Diff test IPv4 with supplied openssl against \"$uri\"";
32-
`$prg $check2run $csvfile $uri 2>&1`;
33+
@args="$prg $check2run $csvfile $uri 2>&1";
34+
system("@args") == 0
35+
or die ("FAILED: \"@args\"");
3336

3437
# 2
3538
printf "\n%s\n", "Diff test IPv4 with $distro_openssl against \"$uri\"";
36-
`$prg $check2run $csvfile2 --openssl=$distro_openssl $uri 2>&1`;
39+
@args="$prg $check2run $csvfile2 --openssl=$distro_openssl $uri 2>&1";
40+
system("@args") == 0
41+
or die ("FAILED: \"@args\" ");
3742

3843
$cat_csvfile = `cat $csvfile`;
3944
$cat_csvfile2 = `cat $csvfile2`;
@@ -50,6 +55,10 @@ $cat_csvfile2 =~ s/HTTP_headerTime.*\n//g;
5055
$cat_csvfile =~ s/"engine_problem.*\n//g;
5156
$cat_csvfile2 =~ s/"engine_problem.*\n//g;
5257

58+
# PR #2628. TL:DR; make the kx between tls_sockets() and openssl the same for this CI run
59+
$cat_csvfile =~ s/ECDH 256/ECDH 253/g;
60+
$cat_csvfile =~ s/ECDH\/MLKEM/ECDH 253 /g;
61+
5362
# Nonce in CSP
5463
$cat_csvfile =~ s/.nonce-.* //g;
5564
$cat_csvfile2 =~ s/.nonce-.* //g;

0 commit comments

Comments
 (0)