Skip to content

Commit 63ebb11

Browse files
committed
Tests: let tests pass on travis-ci VMs with disabled IPv6 loopback.
1 parent 3f027b9 commit 63ebb11

13 files changed

+14
-14
lines changed

access.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ http {
8080
8181
EOF
8282

83-
$t->run()->plan(12);
83+
$t->try_run('no inet6 support')->plan(12);
8484

8585
###############################################################################
8686

debug_connection.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ http {
5252
5353
EOF
5454

55-
$t->run()->plan(5);
55+
$t->try_run('no inet6 support')->plan(5);
5656

5757
###############################################################################
5858

debug_connection_syslog.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ http {
5454
5555
EOF
5656

57-
$t->run()->plan(5);
57+
$t->try_run('no inet6 support')->plan(5);
5858

5959
###############################################################################
6060

geo_ipv6.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ EOF
9191

9292
$t->write_file('index.html', '');
9393
$t->write_file('addr', '');
94-
$t->run();
94+
$t->try_run('no inet6 support');
9595

9696
plan(skip_all => 'no ::1 on host')
9797
if http_get('/addr') !~ /X-IP: ::1/m;

http_resolver_aaaa.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ http {
6767
6868
EOF
6969

70-
$t->run()->plan(72);
70+
$t->try_run('no inet6 support')->plan(72);
7171

7272
$t->run_daemon(\&dns_daemon, port(8081), $t);
7373
$t->run_daemon(\&dns_daemon, port(8082), $t);

proxy_protocol_ipv6.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ stream {
6464
EOF
6565

6666
$t->write_file('t', 'SEE-THIS');
67-
$t->run()->plan(3);
67+
$t->try_run('no inet6 support')->plan(3);
6868

6969
###############################################################################
7070

proxy_ssl_name.t

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ select STDERR; $| = 1;
2424
select STDOUT; $| = 1;
2525

2626
my $t = Test::Nginx->new()->has(qw/http http_ssl sni proxy/)
27-
->has_daemon('openssl')->plan(9)
27+
->has_daemon('openssl')
2828
->write_file_expand('nginx.conf', <<'EOF');
2929
3030
%%TEST_GLOBALS%%
@@ -134,7 +134,7 @@ foreach my $name ('localhost') {
134134

135135
$t->write_file('index.html', '');
136136

137-
$t->run();
137+
$t->try_run('no inet6 support')->plan(9);
138138

139139
###############################################################################
140140

stream_access.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ stream {
146146
147147
EOF
148148

149-
$t->run()->plan(18);
149+
$t->try_run('no inet6 support')->plan(18);
150150
$t->run_daemon(\&stream_daemon);
151151
$t->waitforsocket('127.0.0.1:' . port(8080));
152152

stream_geo_ipv6.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ stream {
8686
8787
EOF
8888

89-
$t->try_run('no stream geo')->plan(6);
89+
$t->try_run('no stream geo or inet6 support')->plan(6);
9090

9191
###############################################################################
9292

stream_proxy_protocol_ipv6.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ stream {
6262
EOF
6363

6464
$t->run_daemon(\&stream_daemon);
65-
$t->run()->plan(2);
65+
$t->try_run('no inet6 support')->plan(2);
6666
$t->waitforsocket('127.0.0.1:' . port(8082));
6767

6868
###############################################################################

stream_realip.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ stream {
8282
EOF
8383

8484
$t->run_daemon(\&stream_daemon);
85-
$t->try_run('no stream proxy_protocol')->plan(8);
85+
$t->try_run('no stream proxy_protocol or inet6 support')->plan(8);
8686
$t->waitforsocket('127.0.0.1:' . port(8081));
8787

8888
###############################################################################

stream_ssl_realip.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ foreach my $name ('localhost') {
101101
or die "Can't create certificate for $name: $!\n";
102102
}
103103

104-
$t->try_run('no stream proxy_protocol')->plan(6);
104+
$t->try_run('no stream proxy_protocol or inet6 support')->plan(6);
105105

106106
###############################################################################
107107

stream_variables.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ stream {
7676
7777
EOF
7878

79-
$t->try_run('no stream return')->plan(8);
79+
$t->try_run('no stream return or inet6 support')->plan(8);
8080

8181
###############################################################################
8282

0 commit comments

Comments
 (0)