Mercurial > hg > nginx-tests
diff proxy_websocket.t @ 974:882267679006
Tests: simplified parallel modifications in tests.
Mail tests were simplified in c227348453db.
author | Andrey Zelenkov <zelenkov@nginx.com> |
---|---|
date | Tue, 12 Jul 2016 17:39:03 +0300 |
parents | e9064d691790 |
children |
line wrap: on
line diff
--- a/proxy_websocket.t +++ b/proxy_websocket.t @@ -47,11 +47,11 @@ http { %%TEST_GLOBALS_HTTP%% server { - listen 127.0.0.1:%%PORT_0%%; + listen 127.0.0.1:8080; server_name localhost; location / { - proxy_pass http://127.0.0.1:%%PORT_1%%; + proxy_pass http://127.0.0.1:8081; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "Upgrade"; @@ -66,7 +66,7 @@ EOF $t->run_daemon(\&websocket_fake_daemon); $t->run(); -$t->waitforsocket('127.0.0.1:' . port(1)) +$t->waitforsocket('127.0.0.1:' . port(8081)) or die "Can't start test backend"; ############################################################################### @@ -125,7 +125,7 @@ sub websocket_connect { my $s = IO::Socket::INET->new( Proto => 'tcp', - PeerAddr => '127.0.0.1:' . port(0) + PeerAddr => '127.0.0.1:' . port(8080) ) or die "Can't connect to nginx: $!\n"; @@ -210,7 +210,7 @@ sub websocket_read { sub websocket_fake_daemon { my $server = IO::Socket::INET->new( Proto => 'tcp', - LocalAddr => '127.0.0.1:' . port(1), + LocalAddr => '127.0.0.1:' . port(8081), Listen => 5, Reuse => 1 )