diff lib/Test/Nginx.pm @ 956:3bc5b72e4377

Tests: fixed exclusive port numbering. To ensure port uniqueness, listen option was added for generated TCP sockets.
author Andrey Zelenkov <zelenkov@nginx.com>
date Wed, 22 Jun 2016 19:46:36 +0300
parents 9361c7eddfc1
children 0641f83d5721
line wrap: on
line diff
--- a/lib/Test/Nginx.pm
+++ b/lib/Test/Nginx.pm
@@ -323,6 +323,7 @@ sub port {
 			Proto => 'tcp',
 			LocalAddr => '127.0.0.1:' . $port,
 			Reuse => 1,
+			Listen => 1,
 		) and last;
 	}