jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/430616 )
Change subject: [test] Test archivebot.str2size for "M" shorthand ......................................................................
[test] Test archivebot.str2size for "M" shorthand
Change-Id: I52b611d803e2af975b7907684bace8d9a00fa494 --- M tests/archivebot_tests.py 1 file changed, 1 insertion(+), 0 deletions(-)
Approvals: Dalba: Looks good to me, approved jenkins-bot: Verified
diff --git a/tests/archivebot_tests.py b/tests/archivebot_tests.py index d1efe6d..f279766 100644 --- a/tests/archivebot_tests.py +++ b/tests/archivebot_tests.py @@ -111,6 +111,7 @@ self.assertEqual(archivebot.str2size('0'), (0, 'B')) self.assertEqual(archivebot.str2size('3000'), (3000, 'B')) self.assertEqual(archivebot.str2size('4 K'), (4096, 'B')) + self.assertEqual(archivebot.str2size('1 M'), (1048576, 'B')) self.assertEqual(archivebot.str2size('2T'), (2, 'T')) # TODO: should probably be recognized 2000? self.assertEqual(archivebot.str2size('2 000'), (2, 'B'))
pywikibot-commits@lists.wikimedia.org