Mercurial > hg > nginx-tests
comparison realip_remote_addr.t @ 1251:766bcbb632ee
Tests: removed TODO and try_run() checks for legacy versions.
author | Sergey Kandaurov <pluknet@nginx.com> |
---|---|
date | Fri, 24 Nov 2017 19:58:40 +0300 |
parents | 9b8e13e2ee67 |
children |
comparison
equal
deleted
inserted
replaced
1250:b708848eb49a | 1251:766bcbb632ee |
---|---|
66 | 66 |
67 like(http_get('/1'), qr/X-Real-IP: 127.0.0.1/m, 'request'); | 67 like(http_get('/1'), qr/X-Real-IP: 127.0.0.1/m, 'request'); |
68 like(http_get('/'), qr/X-Real-IP: 127.0.0.1/m, 'request redirect'); | 68 like(http_get('/'), qr/X-Real-IP: 127.0.0.1/m, 'request redirect'); |
69 | 69 |
70 like(http_xff('/1', '192.0.2.1'), qr/X-Real-IP: 127.0.0.1/m, 'realip'); | 70 like(http_xff('/1', '192.0.2.1'), qr/X-Real-IP: 127.0.0.1/m, 'realip'); |
71 | |
72 TODO: { | |
73 local $TODO = 'not yet' unless $t->has_version('1.11.5'); | |
74 | |
75 like(http_xff('/', '192.0.2.1'), qr/X-Real-IP: 127.0.0.1/m, 'realip redirect'); | 71 like(http_xff('/', '192.0.2.1'), qr/X-Real-IP: 127.0.0.1/m, 'realip redirect'); |
76 | |
77 } | |
78 | 72 |
79 ############################################################################### | 73 ############################################################################### |
80 | 74 |
81 sub http_xff { | 75 sub http_xff { |
82 my ($uri, $xff) = @_; | 76 my ($uri, $xff) = @_; |