(self)
| 527 | self.assertEqual(response_5['xml']['Content'], '<h1>你好</h1>') |
| 528 | |
| 529 | def test_response_image(self): |
| 530 | wechat = WechatBasic() |
| 531 | wechat.parse_data(data=self.test_message) |
| 532 | |
| 533 | resp_xml = wechat.response_image(media_id='xurkvi9gl') |
| 534 | resp = xmltodict.parse(resp_xml) |
| 535 | |
| 536 | self.assertEqual(resp['xml']['ToUserName'], 'fromUser') |
| 537 | self.assertEqual(resp['xml']['FromUserName'], 'toUser') |
| 538 | self.assertEqual(resp['xml']['MsgType'], 'image') |
| 539 | self.assertEqual(resp['xml']['Image']['MediaId'], 'xurkvi9gl') |
| 540 | |
| 541 | def test_response_voice(self): |
| 542 | wechat = WechatBasic() |
nothing calls this directly
no test coverage detected