Exemplo n.º 1
0
 def testGreaterThan1GiB(self):
   self.assertEqual('1.1 GiB (1234567890 Bytes)',
                    admin_request_handler._byte_size_format('1234567890'))
Exemplo n.º 2
0
 def testLessThan1MiB(self):
   self.assertEqual('5.5 KiB (5678 Bytes)',
                    admin_request_handler._byte_size_format('5678'))
Exemplo n.º 3
0
 def testLessThan1GiB(self):
   self.assertEqual('11.8 MiB (12345678 Bytes)',
                    admin_request_handler._byte_size_format('12345678'))
Exemplo n.º 4
0
 def testOneByte(self):
   self.assertEqual('1 Byte',
                    admin_request_handler._byte_size_format('1'))
Exemplo n.º 5
0
 def testLessThan1KiB(self):
   self.assertEqual('123 Bytes',
                    admin_request_handler._byte_size_format('123'))
Exemplo n.º 6
0
 def testGreaterThan1GiB(self):
   self.assertEqual('1.1 GiB (1234567890 Bytes)',
                    admin_request_handler._byte_size_format('1234567890'))
Exemplo n.º 7
0
 def testLessThan1GiB(self):
   self.assertEqual('11.8 MiB (12345678 Bytes)',
                    admin_request_handler._byte_size_format('12345678'))
Exemplo n.º 8
0
 def testLessThan1MiB(self):
   self.assertEqual('5.5 KiB (5678 Bytes)',
                    admin_request_handler._byte_size_format('5678'))
Exemplo n.º 9
0
 def testLessThan1KiB(self):
   self.assertEqual('123 Bytes',
                    admin_request_handler._byte_size_format('123'))
Exemplo n.º 10
0
 def testOneByte(self):
   self.assertEqual('1 Byte',
                    admin_request_handler._byte_size_format('1'))