Add a couple of tests for fold(). One disabled, because the function is broken.

This commit is contained in:
William Grant
2011-03-09 18:47:11 +11:00
parent df2c20d4b3
commit 508ad7ceec
2 changed files with 20 additions and 0 deletions
View File
+20
View File
@@ -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()