diff options
author | wurstsalat <mailtrash@posteo.de> | 2023-02-15 22:48:13 +0300 |
---|---|---|
committer | wurstsalat <mailtrash@posteo.de> | 2023-02-15 22:48:13 +0300 |
commit | b5a3c285d8f9ce50c4daf4b4a57d65b98cb776d4 (patch) | |
tree | 21a26ab50709743fd7ba4f958fe9f636e028c3d6 /test | |
parent | ff12e81a79af55fce738f81b19ab2a9000cf844d (diff) |
cq: Use correct data type for ngettext
Diffstat (limited to 'test')
-rw-r--r-- | test/common/test_get_uf_relative_time.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/test/common/test_get_uf_relative_time.py b/test/common/test_get_uf_relative_time.py index 02f7488db..36958889f 100644 --- a/test/common/test_get_uf_relative_time.py +++ b/test/common/test_get_uf_relative_time.py @@ -30,11 +30,11 @@ class GetRelativeTimeTest(unittest.TestCase): self.assertEqual(get_uf_relative_time(timestamp1.timestamp(), timenow.timestamp()), ngettext( - '%i min ago', - '%i mins ago', + '%s min ago', + '%s mins ago', 3, - 3, - 3)) + str(3), + str(3))) def test_sub_15_minutes_next_day(self): '''Test timedelta less than 15 minutes and it is the next day''' @@ -43,11 +43,11 @@ class GetRelativeTimeTest(unittest.TestCase): self.assertEqual(get_uf_relative_time(timestamp1.timestamp(), timenow.timestamp()), ngettext( - '%i min ago', - '%i mins ago', - 10, + '%s min ago', + '%s mins ago', 10, - 10)) + str(10), + str(10))) def test_today(self): '''Test today: same day and more than 15 minutes ago''' |