1 """
2 Tests the _convertUnitAsWords method.
3 """
4
5 import unittest
6 import parsedatetime as pdt
7
8 -class test(unittest.TestCase):
10 self.cal = pdt.Calendar()
11 self.tests = (('one', 1),
12 ('zero', 0),
13 ('eleven', 11),
14 ('forty two', 42),
15 ('a hundred', 100),
16 ('four hundred and fifteen', 415),
17 ('twelve thousand twenty', 12020),
18 ('nine hundred and ninety nine', 999),
19 ('three quintillion four billion', 3000000004000000000),
20 ('forty three thousand, nine hundred and ninety nine', 43999),
21 ('one hundred thirty three billion four hundred thousand three hundred fourteen', 133000400314),
22 ('an octillion', 1000000000000000000000000000)
23 )
24
28
29 if __name__ == "__main__":
30 unittest.main()
31