testcases.py 文件源码

python
阅读 36 收藏 0 点赞 0 评论 0

项目:functest 作者: opnfv 项目源码 文件源码
def get(self, testcase_name):  # pylint: disable=no-self-use
        """ GET the info of one testcase"""
        testcase = Testcase().show(testcase_name)
        if not testcase:
            return api_utils.result_handler(
                status=1,
                data="The test case '%s' does not exist or is not supported"
                % testcase_name)

        testcase_info = api_utils.change_obj_to_dict(testcase)
        dependency_dict = api_utils.change_obj_to_dict(
            testcase_info.get('dependency'))
        testcase_info.pop('name')
        testcase_info.pop('dependency')
        result = {'testcase': testcase_name}
        result.update(testcase_info)
        result.update({'dependency': dependency_dict})
        return jsonify(result)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号