Buildbot生成器函数buildtest.test

时间:2014-06-09 19:15:11

标签: buildbot

安装Buildbot后,根据getting started docs运行以下命令会出现以下错误:

在终端我输入:PYTHONPATH=. trial buildbot.test

它输出以下错误(在许多成功的测试通过(2362)之后):

[ERROR]
Traceback (most recent call last):
Failure: exceptions.TypeError: <bound method TestLibVirtSlave.test_constructor_minimal of <buildbot.test.unit.test_buildslave_libvirt.TestLibVirtSlave testMethod=test_constructor_minimal>> is a generator function and therefore will never run

buildbot.test.unit.test_buildslave_libvirt.TestLibVirtSlave.test_constructor_minimal
-------------------------------------------------------------------------------
Ran 2371 tests in 9.604s

FAILED (skips=8, errors=1, successes=2362)

1 个答案:

答案 0 :(得分:1)

是的,该测试需要用@defer.inlineCallbacks进行修饰。 Twisted的最新版本(在Buildbot-0.8.8之后发布)将此检测为错误,而旧版本只是默默地忽略它。该修复程序为https://github.com/buildbot/buildbot/commit/de8da868755810e453cbbb6c44793c53bb2f398b