def test_voice_message(self): from wechatpy.messages import VoiceMessage msg = VoiceMessage({ "MediaId": "123456", "Format": "aac", "Recognition": "test", }) self.assertEqual("123456", msg.media_id) self.assertEqual("aac", msg.format) self.assertEqual("test", msg.recognition)
def test_voice_message(self): from wechatpy.messages import VoiceMessage msg = VoiceMessage({ 'MediaId': '123456', 'Format': 'aac', 'Recognition': 'test', }) self.assertEqual('123456', msg.media_id) self.assertEqual('aac', msg.format) self.assertEqual('test', msg.recognition)