def test_location_message(self): from wechatpy.messages import LocationMessage msg = LocationMessage({ "Location_X": "123", "Location_Y": "456", "Scale": "1", "Label": "test", }) self.assertEqual("123", msg.location_x) self.assertEqual("456", msg.location_y) self.assertEqual("1", msg.scale) self.assertEqual("test", msg.label)
def test_location_message(self): from wechatpy.messages import LocationMessage msg = LocationMessage({ 'Location_X': '123', 'Location_Y': '456', 'Scale': '1', 'Label': 'test', }) self.assertEqual('123', msg.location_x) self.assertEqual('456', msg.location_y) self.assertEquals('1', msg.scale) self.assertEqual('test', msg.label)