def test_hex_string_to_byte_array(self): inp = '49276d206b696c6c696e6720796f757220627261696e206c696b65206120706f69736f6e6f7573206d757368726f6f6d' expected = bytearray('I\'m killing your brain like a poisonous mushroom') out = EncodingUtils.hex_string_to_byte_array(inp) self.assertEqual(out, expected)
def test_hex_string_to_byte_array(self): inp = '49276d206b696c6c696e6720796f757220627261696e206c696b65206120706f69736f6e6f7573206d757368726f6f6d' expected = bytearray( 'I\'m killing your brain like a poisonous mushroom') out = EncodingUtils.hex_string_to_byte_array(inp) self.assertEqual(out, expected)