# HG changeset patch # User Bryan O'Sullivan # Date 2012-11-16 06:24:36 # Node ID f945caa5e96365753526d6657c676542b8926ce6 # Parent 1e13b118429265dd3a395ffe93e6b6da3290679d test-pathencode: more aggressively check for python < 2.6 diff --git a/tests/test-pathencode.py b/tests/test-pathencode.py --- a/tests/test-pathencode.py +++ b/tests/test-pathencode.py @@ -10,6 +10,9 @@ from mercurial import store import binascii, itertools, math, os, random, sys, time import collections +if sys.version_info[:2] < (2, 6): + sys.exit(0) + def hybridencode(path): return store._hybridencode(path, True) @@ -186,5 +189,5 @@ def main(): if runtests(rng, seed, count): sys.exit(1) -if __name__ == '__main__' and sys.version_info[:2] >= (2, 6): +if __name__ == '__main__': main()