示例#1
0
 def test_bitlist_to_string(self):
     string = 'foo'
     bitlist = [
         0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1,
         1, 1
     ]
     self.assertEqual(utils_misc.string_to_bitlist(string), bitlist)
示例#2
0
 def test_bitlist_to_string(self):
     string = 'foo'
     bitlist = [0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1]
     self.assertEqual(utils_misc.string_to_bitlist(string), bitlist)