Mercurial > hg > nginx-tests
comparison proxy_ssl_name.t @ 568:907e89fba9c3
Tests: removed TODO and try_run() checks for legacy versions.
author | Sergey Kandaurov <pluknet@nginx.com> |
---|---|
date | Sun, 03 May 2015 12:45:09 +0300 |
parents | 3c9aeeb09ac8 |
children | e9064d691790 |
comparison
equal
deleted
inserted
replaced
567:22bade4c7e12 | 568:907e89fba9c3 |
---|---|
22 | 22 |
23 select STDERR; $| = 1; | 23 select STDERR; $| = 1; |
24 select STDOUT; $| = 1; | 24 select STDOUT; $| = 1; |
25 | 25 |
26 my $t = Test::Nginx->new()->has(qw/http http_ssl sni proxy/) | 26 my $t = Test::Nginx->new()->has(qw/http http_ssl sni proxy/) |
27 ->has_daemon('openssl') | 27 ->has_daemon('openssl')->plan(8) |
28 ->write_file_expand('nginx.conf', <<'EOF'); | 28 ->write_file_expand('nginx.conf', <<'EOF'); |
29 | 29 |
30 %%TEST_GLOBALS%% | 30 %%TEST_GLOBALS%% |
31 | 31 |
32 daemon off; | 32 daemon off; |
132 or die "Can't create certificate for $name: $!\n"; | 132 or die "Can't create certificate for $name: $!\n"; |
133 } | 133 } |
134 | 134 |
135 $t->write_file('index.html', ''); | 135 $t->write_file('index.html', ''); |
136 | 136 |
137 $t->try_run('no proxy_ssl_name')->plan(8); | 137 $t->run(); |
138 | 138 |
139 ############################################################################### | 139 ############################################################################### |
140 | 140 |
141 like(http_get('/1'), qr/200 OK.*X-Name: 1.example.com,/ms, 'name 1'); | 141 like(http_get('/1'), qr/200 OK.*X-Name: 1.example.com,/ms, 'name 1'); |
142 like(http_get('/2'), qr/200 OK.*X-Name: 2.example.com,/ms, 'name 2'); | 142 like(http_get('/2'), qr/200 OK.*X-Name: 2.example.com,/ms, 'name 2'); |