From 0ec711f3bf00bbfe372cef4396880d0ba55fafe0 Mon Sep 17 00:00:00 2001 From: Iustin Pop Date: Sun, 27 Dec 2009 13:59:06 +0100 Subject: [PATCH] Fix unittest suite compatibility with python2.6 It turns out imports by filename were never supposed to work, and python2.6 just errors out explicitly. --- Makefile | 7 +++++-- setup.py | 2 +- tests/__init__.py | 0 {test => tests}/test_acls.py | 0 4 files changed, 6 insertions(+), 3 deletions(-) create mode 100644 tests/__init__.py rename {test => tests}/test_acls.py (100%) diff --git a/Makefile b/Makefile index 354046f..e8fde0c 100644 --- a/Makefile +++ b/Makefile @@ -14,5 +14,8 @@ doc: posix1e.so posix1e test: - python2.4 ./setup.py test - python2.5 ./setup.py test + for ver in 2.4 2.5 2.6; do \ + if type python$$ver >/dev/null; then \ + python$$ver ./setup.py test; \ + fi; \ + done diff --git a/setup.py b/setup.py index bf2b721..c6f7116 100755 --- a/setup.py +++ b/setup.py @@ -44,5 +44,5 @@ setup(name="pylibacl", libraries=libs, define_macros=macros, )], - test_suite="test/test_acls", + test_suite="tests", ) diff --git a/tests/__init__.py b/tests/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/test/test_acls.py b/tests/test_acls.py similarity index 100% rename from test/test_acls.py rename to tests/test_acls.py -- 2.39.2