compatibility with Python 2.6+ and Python 3.x
This commit is contained in:
5
tests.py
5
tests.py
@@ -1,6 +1,7 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
|
from __future__ import print_function
|
||||||
import doctest
|
import doctest
|
||||||
import unittest
|
import unittest
|
||||||
import sys
|
import sys
|
||||||
@@ -37,7 +38,7 @@ if coverage is not None:
|
|||||||
coverage.erase()
|
coverage.erase()
|
||||||
|
|
||||||
if coverage is None:
|
if coverage is None:
|
||||||
print >>sys.stderr, """
|
print("""
|
||||||
No coverage reporting done (Python module "coverage" is missing)
|
No coverage reporting done (Python module "coverage" is missing)
|
||||||
Please install the python-coverage package to get coverage reporting.
|
Please install the python-coverage package to get coverage reporting.
|
||||||
"""
|
""", file=sys.stderr)
|
||||||
|
|||||||
Reference in New Issue
Block a user