From c118adc705c49a9fbacc87023bbe084f79b8e811 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lubom=C3=ADr=20Sedl=C3=A1=C5=99?= Date: Thu, 22 Sep 2016 10:28:01 +0200 Subject: [PATCH] tests: Use unittest2 consistently MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Without importing this module, the tests are going to fail on Python 2.6. Signed-off-by: Lubomír Sedlář --- tests/test_config.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/test_config.py b/tests/test_config.py index 48678872..31d2f3f9 100644 --- a/tests/test_config.py +++ b/tests/test_config.py @@ -2,7 +2,10 @@ # -*- coding: utf-8 -*- -import unittest +try: + import unittest2 as unittest +except ImportError: + import unittest import os import sys