summaryrefslogtreecommitdiff
path: root/test.py
diff options
context:
space:
mode:
authorStefan Behnel <stefan_ml@behnel.de>2012-11-20 19:57:04 +0100
committerStefan Behnel <stefan_ml@behnel.de>2012-11-20 19:57:04 +0100
commitce3051e953e6ba1938712f15246feb74bdec84dd (patch)
tree037a126c4fbc67dc2e2480bc8538ad269a63a691 /test.py
parent4ddb818394db40e60a95213995df65ab8fe5b830 (diff)
downloadpython-lxml-ce3051e953e6ba1938712f15246feb74bdec84dd.tar.gz
exclude new xmlfile() tests in Py2.4 as they require the 'with' statement
Diffstat (limited to 'test.py')
-rw-r--r--test.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/test.py b/test.py
index 2a889aea..008da074 100644
--- a/test.py
+++ b/test.py
@@ -561,6 +561,12 @@ def main(argv):
# Finding and importing
test_files = get_test_files(cfg)
+
+ if sys.version_info[:2] < (2,5):
+ # 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 ]
+
if cfg.list_tests or cfg.run_tests:
test_cases = get_test_cases(test_files, cfg, tracer=tracer)
if cfg.list_hooks or cfg.run_tests: