创建robotframework自定义词库 发表于 2019-08-23 更新于 2022-05-09 创建robotframework自定义词库 在你的项目的python环境下创建自定义的库的文件夹。 例如: 1python_path\Lib\site-packages\CustomLibrary 创建 init.py1234from .customClass import CustomClassclass CustomLibrary(CustomClass): ROBOT_LIBRARY_SCOPE = 'GLOBAL' 创建 customClass.py123456class CustomClass(object): def __init__(self): pass def customLog(self,msg): print('custom log:'+msg) 再用例中导入库 12*** Settings ***Library CustomLibrary