Searched refs:BytesToHumanReadable (Results 1 – 4 of 4) sorted by relevance
/system/update_engine/scripts/update_payload/ |
D | format_utils_unittest.py | 47 self.assertEqual(format_utils.BytesToHumanReadable(0x1000), '4 KiB') 48 self.assertEqual(format_utils.BytesToHumanReadable(0x400000), '4 MiB') 49 self.assertEqual(format_utils.BytesToHumanReadable(0x100000000), '4 GiB') 50 self.assertEqual(format_utils.BytesToHumanReadable(0x40000000000), '4 TiB') 53 self.assertEqual(format_utils.BytesToHumanReadable(5000, decimal=True), 55 self.assertEqual(format_utils.BytesToHumanReadable(5000000, decimal=True), 57 self.assertEqual(format_utils.BytesToHumanReadable(5000000000, 62 self.assertEqual(format_utils.BytesToHumanReadable(5000), '4.8 KiB') 63 self.assertEqual(format_utils.BytesToHumanReadable(500000), '488.2 KiB') 64 self.assertEqual(format_utils.BytesToHumanReadable(5000000), '4.7 MiB') [all …]
|
D | format_utils.py | 55 def BytesToHumanReadable(size, precision=1, decimal=False): function
|
D | histogram_unittest.py | 19 fmt = format_utils.BytesToHumanReadable(size)
|
D | checker.py | 92 return _AddFormat(format_utils.BytesToHumanReadable, size)
|