mirror of
https://github.com/nmap/nmap.git
synced 2025-12-22 23:49:03 +00:00
Automatically XFAIL SCTP tests on Windows.
This commit is contained in:
@@ -26,6 +26,8 @@ my $PROXY_PORT = 40001;
|
|||||||
my $UNIXSOCK = "ncat.unixsock";
|
my $UNIXSOCK = "ncat.unixsock";
|
||||||
my $UNIXSOCK_TMP = "ncat.unixsock_tmp";
|
my $UNIXSOCK_TMP = "ncat.unixsock_tmp";
|
||||||
|
|
||||||
|
my $HAVE_SCTP = !($^O eq "MSWin32" || $^O eq "cygwin");
|
||||||
|
|
||||||
my $BUFSIZ = 1024;
|
my $BUFSIZ = 1024;
|
||||||
|
|
||||||
my $num_tests = 0;
|
my $num_tests = 0;
|
||||||
@@ -184,13 +186,12 @@ sub server_client_test_multi {
|
|||||||
my $client_args_ref = shift;
|
my $client_args_ref = shift;
|
||||||
my $code = shift;
|
my $code = shift;
|
||||||
my $outer_xfail = $xfail;
|
my $outer_xfail = $xfail;
|
||||||
local $xfail;
|
|
||||||
|
|
||||||
for my $spec (@$specs) {
|
for my $spec (@$specs) {
|
||||||
my @server_args = @$server_args_ref;
|
my @server_args = @$server_args_ref;
|
||||||
my @client_args = @$client_args_ref;
|
my @client_args = @$client_args_ref;
|
||||||
|
|
||||||
$xfail = $outer_xfail;
|
local $xfail = $outer_xfail;
|
||||||
for my $proto (split(/ /, $spec)) {
|
for my $proto (split(/ /, $spec)) {
|
||||||
if ($proto eq "tcp") {
|
if ($proto eq "tcp") {
|
||||||
# Nothing needed.
|
# Nothing needed.
|
||||||
@@ -200,6 +201,7 @@ sub server_client_test_multi {
|
|||||||
} elsif ($proto eq "sctp") {
|
} elsif ($proto eq "sctp") {
|
||||||
push @server_args, ("--sctp");
|
push @server_args, ("--sctp");
|
||||||
push @client_args, ("--sctp");
|
push @client_args, ("--sctp");
|
||||||
|
$xfail = 1 if !$HAVE_SCTP;
|
||||||
} elsif ($proto eq "ssl") {
|
} elsif ($proto eq "ssl") {
|
||||||
push @server_args, ("--ssl", "--ssl-key", "test-cert.pem", "--ssl-cert", "test-cert.pem");
|
push @server_args, ("--ssl", "--ssl-key", "test-cert.pem", "--ssl-cert", "test-cert.pem");
|
||||||
push @client_args, ("--ssl");
|
push @client_args, ("--ssl");
|
||||||
|
|||||||
Reference in New Issue
Block a user