diff --git a/dkim/tests/__init__.py b/dkim/tests/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/dkim/tests/test_dkim.py b/dkim/tests/test_dkim.py new file mode 100644 index 0000000..c7b271e --- /dev/null +++ b/dkim/tests/test_dkim.py @@ -0,0 +1,20 @@ +import unittest + +import dkim + + +class TestFold(unittest.TestCase): + + def test_short_line(self): + self.assertEqual( + "foo", dkim.fold("foo")) + + def DISABLED_test_long_line(self): + # The function is terribly broken, not passing even this simple + # test. + self.assertEqual( + "foo"*24 + "\r\n foo", dkim.fold("foo" * 25)) + + +if __name__ == '__main__': + unittest.main()