tests/hghave.py
changeset 32726 a6e4c4218b71
parent 32474 c2b7fb580794
child 32770 9cf74abd1252
--- a/tests/hghave.py	Tue Jun 06 11:02:30 2017 -0400
+++ b/tests/hghave.py	Tue Jun 06 11:16:10 2017 -0400
@@ -634,3 +634,12 @@
 @check("devfull", "/dev/full special file")
 def has_dev_full():
     return os.path.exists('/dev/full')
+
+@check("virtualenv", "Python virtualenv support")
+def has_virtualenv():
+    try:
+        import virtualenv
+        virtualenv.ACTIVATE_SH
+        return True
+    except ImportError:
+        return False