【发布时间】:2013-08-22 06:30:43
【问题描述】:
我正在尝试在Eclipse 中使用Behave 构建BDD 测试环境。每当我从 import 定义开始时,from behave import * Eclipse 就会引发 import 警告。
另外,given、when 和 then 的装饰器标记为 undefined variables。
有人知道为什么decorators 没有被导入吗?
使用from behave import *时的错误信息
Unused in wild import: AmbiguousStep, StepRegistry, i18n, importer, json_parser, log_capture, matchers, model, names, runner, runner_util, setup_step_decorators, step_matcher, step_registry, tag_expression, textutil... others suppressed
装饰器的错误信息:
Undefined variable: given
【问题讨论】:
-
你能添加你的错误信息吗?
-
添加了错误信息
-
"Unused in wild import" 是一个警告 ;-) 尝试显式导入:例如从给定的行为导入,然后,步骤Some hints about behave