--- /dev/null
+# The software in this package is distributed under the GNU General
+# Public License version 2 (with a special exception described below).
+#
+# A copy of GNU General Public License (GPL) is included in this distribution,
+# in the file COPYING.GPL.
+#
+# As a special exception, if other files instantiate templates or use macros
+# or inline functions from this file, or you compile this file and link it
+# with other works to produce a work based on this file, this file
+# does not by itself cause the resulting work to be covered
+# by the GNU General Public License.
+#
+# However the source code for this file must still be made available
+# in accordance with section (3) of the GNU General Public License.
+#
+# This exception does not invalidate any other reasons why a work based
+# on this file might be covered by the GNU General Public License.
+
+""" test_text_helpers.py: unit tests for text_helpers
+
+Tests classes and functions in text_helpers
+
+Should be able run from python2 and python3!
+
+For help see :py:mod:`unittest`
+
+.. codeauthor:: Intra2net
+"""
+
+from __future__ import print_function
+
+import unittest
+
+import text_helpers
+
+
+class TextHelpersTester(unittest.TestCase):
+ """
+ hard to test whether functions work correctly, can only check no raise
+ """
+
+ def test_shortcuts_do_not_raise(self):
+ """ tests all shortcut functions """
+ for color in COLOR_BLACK, COLOR_RED, COLOR_GREEN, COLOR_YELLOW, \
+ COLOR_BLUE, COLOR_MAGENTA, COLOR_CYAN, COLOR_WHITE:
+ exec('{0}("{0}")'.format(color))
+ for style in 'normal', 'bold', 'underline', 'blink', 'reverse':
+ exec('{0}("{0}")'.format(style))
+
+
+if __name__ == '__main__':
+ unittest.main()