summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Behnel <stefan_ml@behnel.de>2013-04-28 15:24:21 +0200
committerStefan Behnel <stefan_ml@behnel.de>2013-04-28 15:24:21 +0200
commitedd23c372e853a9a11f8a07cda11525f518dcbb1 (patch)
tree28fad387b719b669f2da6d70f1283abe4acb14ce
parent3e7c45c5bcad2c5ddcaf57ffc2cf1c186ba46093 (diff)
downloadpython-lxml-edd23c372e853a9a11f8a07cda11525f518dcbb1.tar.gz
exclude HTTP client tests in old Python versions
-rw-r--r--test.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/test.py b/test.py
index 5ae42e01..867d98ed 100644
--- a/test.py
+++ b/test.py
@@ -566,8 +566,13 @@ def main(argv):
# exclude tests that require the 'with' statement
test_files = [
test_file for test_file in test_files
- if 'test_incremental_xmlfile.py' not in test_file
- and 'test_http_io.py' not in test_file]
+ if 'test_incremental_xmlfile.py' not in test_file]
+
+ if sys.version_info[:2] < (2,6):
+ # exclude tests that require recent Python features
+ test_files = [
+ test_file for test_file in test_files
+ if 'test_http_io.py' not in test_file]
if cfg.list_tests or cfg.run_tests:
test_cases = get_test_cases(test_files, cfg, tracer=tracer)