我目前正在为一个项目使用robot框架和Gherkin语言策略(在那时候给出)。在
我的功能文件如下:
*** Settings ***
Documentation
... In Order to eat a dessert safely,
... As a king
... I want to not take a lethal dessert
Library eat_or_pass.Eat_or_pass
*** Test cases ***
Lethal Dessert
[Template] The result of ${hungriness} should be ${dessert}
very hungry apple pie
hungry biscuit
not very hungry apple
*** Keywords ***
The result of ${hungriness} should be ${dessert}
Given the king is ${hungriness}
Then the related dessert is ${dessert}
我想将关键字“Given the king is${hungriness}”链接到python模块Eat\u或中包含的python定义_通过.py目前实施情况如下:
^{pr2}$运行robot framework时,出现以下错误: “致命甜点|失败| 找不到名为“Given the king is${hungriness}”的关键字。“ 我不知道怎么解决。有人能在这个问题上帮助我吗?在
机器人代码:
python库:
^{pr2}$我建议您在python中使用CamelCase,在RF中使用4个空格(更好的可读性)。在
应该是因为国王饿了而不是因为国王${Hungriness}
^{pr2}$相关问题 更多 >
编程相关推荐