[commons.util] refactoring: always strips unit string in 'size_to_byte'

This commit is contained in:
Vinicius Moreira
2022-04-06 10:44:42 -03:00
parent 47cb969f1a
commit 887ae2da5c
2 changed files with 2 additions and 2 deletions

View File

@@ -41,4 +41,4 @@ class SizeToByteTest(TestCase):
self.assertEqual(6383852471797678, size_to_byte('5.67', 'P'))
def test_must_treat_string_sizes_before_converting(self):
self.assertEqual(58675.2, size_to_byte(' 57 , 3 ', 'K'))
self.assertEqual(58675.2, size_to_byte(' 57 , 3 ', ' K '))