[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor/master] Check Python version in test_rebind.py



commit d40b0e73c278cd54c6c4765f35b4d031a5882562
Author: rl1987 <rl1987@xxxxxxxxxxxxxxxx>
Date:   Fri Sep 14 20:13:23 2018 +0300

    Check Python version in test_rebind.py
---
 src/test/test_rebind.py | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/test/test_rebind.py b/src/test/test_rebind.py
index 42a4658b4..7ba3a5796 100644
--- a/src/test/test_rebind.py
+++ b/src/test/test_rebind.py
@@ -35,6 +35,12 @@ def pick_random_port():
 
     return port
 
+if sys.hexversion < 0x02070000:
+    sys.exit("ERROR: unsupported Python version (should be >= 2.7)")
+
+if sys.hexversion > 0x03000000 and sys.hexversion < 0x03010000:
+    sys.exit("ERROR: unsupported Python3 version (should be >= 3.1)")
+
 control_port = pick_random_port()
 socks_port = pick_random_port()
 



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits