forked from pool/python-html2text
Added remove_unittest2.patch to facilitate that OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-html2text?expand=0&rev=25
65 lines
1.7 KiB
Diff
65 lines
1.7 KiB
Diff
--- a/setup.py
|
|
+++ b/setup.py
|
|
@@ -9,14 +9,7 @@ try:
|
|
except ImportError:
|
|
read_md = lambda f: open(f, 'r').read()
|
|
|
|
-requires_list = []
|
|
-try:
|
|
- import unittest2 as unittest
|
|
-except ImportError:
|
|
- import unittest
|
|
-else:
|
|
- if sys.version_info <= (2, 6):
|
|
- requires_list.append("unittest2")
|
|
+import unittest
|
|
|
|
|
|
class RunTests(Command):
|
|
@@ -59,9 +52,6 @@ setup(
|
|
'Operating System :: OS Independent',
|
|
'Programming Language :: Python',
|
|
'Programming Language :: Python :: 2',
|
|
- 'Programming Language :: Python :: 2.4',
|
|
- 'Programming Language :: Python :: 2.5',
|
|
- 'Programming Language :: Python :: 2.6',
|
|
'Programming Language :: Python :: 2.7',
|
|
'Programming Language :: Python :: 3',
|
|
'Programming Language :: Python :: 3.0',
|
|
@@ -75,7 +65,6 @@ setup(
|
|
html2text=html2text.cli:main
|
|
""",
|
|
license='GNU GPL 3',
|
|
- requires=requires_list,
|
|
packages=find_packages(exclude=['test']),
|
|
include_package_data=True,
|
|
zip_safe=False,
|
|
--- a/test/test_html2text.py
|
|
+++ b/test/test_html2text.py
|
|
@@ -5,10 +5,7 @@ import re
|
|
import subprocess
|
|
import sys
|
|
|
|
-if sys.version_info[:2] < (2, 7):
|
|
- import unittest2 as unittest
|
|
-else:
|
|
- import unittest
|
|
+import unittest
|
|
import logging
|
|
|
|
logging.basicConfig(format='%(levelname)s:%(funcName)s:%(message)s',
|
|
--- a/test/test_memleak.py
|
|
+++ b/test/test_memleak.py
|
|
@@ -1,9 +1,7 @@
|
|
import sys
|
|
-if sys.version_info[:2] < (2, 7):
|
|
- import unittest2 as unittest
|
|
-else:
|
|
- import unittest
|
|
import logging
|
|
+import unittest
|
|
+
|
|
logging.basicConfig(format='%(levelname)s:%(funcName)s:%(message)s',
|
|
level=logging.DEBUG)
|
|
|