]> diplodocus.org Git - nmh/commitdiff
Calculate port numbers in test suite based on uid so that different
authorDavid Levine <levinedl@acm.org>
Sat, 11 Jan 2014 17:22:50 +0000 (11:22 -0600)
committerDavid Levine <levinedl@acm.org>
Sat, 11 Jan 2014 17:22:50 +0000 (11:22 -0600)
users can run the test suite on a host simultaneously.

test/inc/test-pop
test/post/test-post-common.sh

index 01b32a13478053f9071046900a5c4561ab0646d1..960727d63a255d28c1f8207e40dde171775a9eb5 100755 (executable)
@@ -24,7 +24,8 @@ setup_test
 
 TESTUSER=testuser
 TESTPASS=testuserpass
 
 TESTUSER=testuser
 TESTPASS=testuserpass
-testport=65413
+arith_eval 64001 + `id -u` % 1000
+testport=$arith_val
 
 HOME="${MH_TEST_DIR}"; export HOME
 netrc="${HOME}/.netrc"
 
 HOME="${MH_TEST_DIR}"; export HOME
 netrc="${HOME}/.netrc"
index 6767d747bfec44e47dade98d29157bcd3d6d0052..5692cc66c35129af7ccad34ef63405e49a4bb3bb 100755 (executable)
@@ -9,7 +9,8 @@ set -e
 
 setup_test
 
 
 setup_test
 
-localport=65412
+arith_eval 64000 + `id -u` % 1000
+localport=$arith_val
 testname="${MH_TEST_DIR}/$$"
 
 #
 testname="${MH_TEST_DIR}/$$"
 
 #