def test_update_channel_id_null(self): """ 测试请求接口渠道参数为空 :return: """ check_version_api = CheckVersionApi() check_version_api.get({ 'platform': 'ios', 'pname': self.pname, 'channel_id': None }) self.assertEqual(check_version_api.get_code(), 401002) self.assertEqual(check_version_api.get_response_message(), u'缺少渠道参数')
def test_update_platform_error(self): """ 测试请求接口平台参数错误 :return: """ check_version_api = CheckVersionApi() check_version_api.get({ 'platform': '123', 'pname': self.pname, 'channel_id': self.ios_channel_id }) self.assertEqual(check_version_api.get_code(), 401000) self.assertEqual(check_version_api.get_response_message(), u'缺少平台信息参数')