首页
学习
活动
专区
工具
TVP
发布
社区首页 >问答首页 >如何为bazel测试指定自定义超时

如何为bazel测试指定自定义超时
EN

Stack Overflow用户
提问于 2018-06-15 22:20:51
回答 1查看 4.7K关注 0票数 8

在我的设置(版本0.12.0)中,bazel test命令对标记为size = small的测试使用默认超时75秒(而documentation提到这是60秒)

有没有一种方法可以在bazel命令行上提供自定义超时,比如10秒,以便在测试挂起时更快地终止测试?

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2018-06-18 06:06:31

我希望我没有误解这个问题,但这听起来真的像是您在寻找--test_timeout选项:

代码语言:javascript
复制
  --test_timeout
    (a single integer or comma-separated list of 4 integers; default: "-1")
    Override the default test timeout values for test timeouts (in secs). If a 
    single positive integer value is specified it will override all 
    categories.  If 4 comma-separated integers are specified, they will 
    override the timeouts for short, moderate, long and eternal (in that 
    order). In either form, a value of -1 tells blaze to use its default 
    timeouts for that category.

如果您希望每次都使用相同的选项,则可以使用bazelrc省去一些键入操作。

票数 9
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/50877472

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档