diff tests/hghave.py @ 29630:f74eed3115fd

hghave: add "chg" flag to skip tests that can't be compatible with chg Several tests fail with chg for several reasons such as loaded chgserver extension, running uisetup() per server instead of per runcommand, etc. Since these tests can't/shouldn't be changed to be chg friendly, we need a flag to skip them. This patch explicitly drops CHGHG environment if chg isn't involved. This way, hghave can just check if CHGHG exists.
author Yuya Nishihara <yuya@tcha.org>
date Sun, 20 Mar 2016 14:55:56 -0700
parents 08a686a4a0a2
children aa927b0a5b87
line wrap: on
line diff
--- a/tests/hghave.py
+++ b/tests/hghave.py
@@ -124,6 +124,10 @@
     except ImportError:
         return False
 
+@check("chg", "running with chg")
+def has_chg():
+    return 'CHGHG' in os.environ
+
 @check("cvs", "cvs client/server")
 def has_cvs():
     re = r'Concurrent Versions System.*?server'