mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 05:09:23 +01:00
This episode was brought to you by the letter 't' as in 'test'. More tests are
good.
This commit is contained in:
parent
2d21655cb2
commit
2c5e6163a0
@ -59,6 +59,8 @@ class UtilsTest(unittest.TestCase):
|
||||
self.assertEqual('fishes', f('fish', 2))
|
||||
self.assertEqual('try', f('try', 1))
|
||||
self.assertEqual('tries', f('try', 2))
|
||||
self.assertEqual('day', f('day', 1))
|
||||
self.assertEqual('days', f('day', 2))
|
||||
|
||||
def testDepluralize(self):
|
||||
f = utils.depluralize
|
||||
@ -81,7 +83,10 @@ class UtilsTest(unittest.TestCase):
|
||||
(62, '1 minute and 2 seconds'),
|
||||
(122, '2 minutes and 2 seconds'),
|
||||
(3722, '1 hour, 2 minutes, and 2 seconds'),
|
||||
(7322, '2 hours, 2 minutes, and 2 seconds')]:
|
||||
(7322, '2 hours, 2 minutes, and 2 seconds'),
|
||||
(90061,'1 day, 1 hour, 1 minute, and 1 second'),
|
||||
(180122, '2 days, 2 hours, 2 minutes, '
|
||||
'and 2 seconds')]:
|
||||
self.assertEqual(utils.timeElapsed(now - then), expected)
|
||||
|
||||
def testEachSubstring(self):
|
||||
|
Loading…
Reference in New Issue
Block a user