gtest.py 文件源码

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

项目:ave 作者: sonyxperiadev 项目源码 文件源码
def t05(w,h):
    pretty = '%s t5' % __file__
    print(pretty)

    result_path = w.make_tempdir()
    os.chmod(result_path, stat.S_IRUSR) # user read permission only
    try:
        h.run_gtest('some_target', result_path)
        print(
            'FAIL %s: expected error (not writable result directory): %s'
            % (pretty, temp_dir)
        )
        return False
    except Exception as e:
        if e.message != 'result_path not a writable directory: %s' % result_path:
            print('FAIL %s: wrong error message: %s' % (pretty, str(e)))
            return False
    finally:
        os.removedirs(result_path)
    return True

# successful execution of run_gtest(): check files on host, verfiy their
#   content and that traces from run removed from handset
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号