本文介绍了Robot Framework:: 导入的库“class"不包含关键字的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用 python 创建 Robot Framework 关键字当我只使用函数时,RIDE 可以检测到关键字
I am creating Robot Framework keyword using pythonWhen I use only function, then RIDE can detect the keyword
def hello_world (patient):
print ('Hello')
但是当我使用
class helloAll(object):
def hello_world (patient):
print ('Hello')
我添加的库如下
*** Settings ***
Library hello
我已将 .py
文件放在与测试用例相同的目录中.
I have placed the .py
file in the same directory as the test case.
Imported library "Name of the Class" contains no keywords
请帮忙.
谢谢.
推荐答案
好的我发现我的错误,我需要把 Library fileName.ClassName ,它解决了问题
Ok I found my mistake, I needed to put Library fileName.ClassName , it fixed the issue
这篇关于Robot Framework:: 导入的库“class"不包含关键字的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!