Tests: skip UDP tests on win32, udp feature introduced. The UDP sockets are not supported in nginx on this platform.
diff --git a/lib/Test/Nginx.pm b/lib/Test/Nginx.pm index 9688875..21e88a5 100644 --- a/lib/Test/Nginx.pm +++ b/lib/Test/Nginx.pm
@@ -198,6 +198,10 @@ return $^O ne 'MSWin32'; } + if ($feature eq 'udp') { + return $^O ne 'MSWin32'; + } + return 0; }
diff --git a/stream_udp_limit_conn.t b/stream_udp_limit_conn.t index 64e40e7..671356a 100644 --- a/stream_udp_limit_conn.t +++ b/stream_udp_limit_conn.t
@@ -23,7 +23,7 @@ select STDERR; $| = 1; select STDOUT; $| = 1; -my $t = Test::Nginx->new()->has(qw/stream stream_limit_conn shmem/) +my $t = Test::Nginx->new()->has(qw/stream stream_limit_conn udp shmem/) ->write_file_expand('nginx.conf', <<'EOF'); %%TEST_GLOBALS%%
diff --git a/stream_udp_proxy.t b/stream_udp_proxy.t index 2d57c1b..ad50cf7 100644 --- a/stream_udp_proxy.t +++ b/stream_udp_proxy.t
@@ -22,7 +22,7 @@ select STDERR; $| = 1; select STDOUT; $| = 1; -my $t = Test::Nginx->new()->has(qw/stream/) +my $t = Test::Nginx->new()->has(qw/stream udp/) ->write_file_expand('nginx.conf', <<'EOF'); %%TEST_GLOBALS%%
diff --git a/stream_udp_upstream.t b/stream_udp_upstream.t index 30fc6bb..6c53669 100644 --- a/stream_udp_upstream.t +++ b/stream_udp_upstream.t
@@ -23,7 +23,7 @@ select STDERR; $| = 1; select STDOUT; $| = 1; -my $t = Test::Nginx->new()->has(qw/stream/) +my $t = Test::Nginx->new()->has(qw/stream udp/) ->write_file_expand('nginx.conf', <<'EOF'); %%TEST_GLOBALS%%
diff --git a/stream_udp_upstream_hash.t b/stream_udp_upstream_hash.t index 8fb39fe..89886cd 100644 --- a/stream_udp_upstream_hash.t +++ b/stream_udp_upstream_hash.t
@@ -23,7 +23,7 @@ select STDERR; $| = 1; select STDOUT; $| = 1; -my $t = Test::Nginx->new()->has(qw/stream stream_upstream_hash/); +my $t = Test::Nginx->new()->has(qw/stream stream_upstream_hash udp/); $t->write_file_expand('nginx.conf', <<'EOF');
diff --git a/stream_udp_upstream_least_conn.t b/stream_udp_upstream_least_conn.t index 298fb05..f49f0cb 100644 --- a/stream_udp_upstream_least_conn.t +++ b/stream_udp_upstream_least_conn.t
@@ -23,7 +23,7 @@ select STDERR; $| = 1; select STDOUT; $| = 1; -my $t = Test::Nginx->new()->has(qw/stream stream_upstream_least_conn/) +my $t = Test::Nginx->new()->has(qw/stream stream_upstream_least_conn udp/) ->write_file_expand('nginx.conf', <<'EOF'); %%TEST_GLOBALS%%