run_test_suite.py 文件源码

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

项目:heerkat 作者: Roche 项目源码 文件源码
def parse_args():
    parser = OptionParser()
    parser.add_option('--detailed_output', nargs=1,
                      help='specify path where detailed logs can be found')
    parser.add_option('--monitored_output', nargs=1,
                      help='specify path where monitored logs can be found')
    parser.add_option('--test_suite', nargs=1, choices=['availability.service_tests', ],
                      help='specify the test suite (python module) that you wish to execute')

    (options, args) = parser.parse_args()

    if not options.test_suite:  # Python 2.6 strikes again! Use argparse after Python upgrade
        parser.error('test_suite not given')
    if not options.monitored_output:
        parser.error('monitored_output not given')
    if not options.detailed_output:
        parser.error('detailed_output not given')

    return options
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号