如何在机器人框架中导入JAR或Java代码使用Java中定义的方法



我遵循了链接中提供的所有步骤https://blog.codecentric.de/en/2012/06/robot-framework-tutorial-writing-writing-keyword-libraries-in-java/

  • 文件夹结构
  • 运行jybot

控制台:

c: robot excution local scripts> start_samplelibrary_testsuite.batC: robot excution local scripts> del ...... output*.xml/q该系统找不到指定的文件。c: robot excution local scripts> del ...... output*.html/q该系统找不到指定的文件。c: robot excution local scripts> del ...... output*.png/q该系统找不到指定的文件。c: robot recution local scripts> set classpath =" .... lib samplelibrary.jar;" .... lib samplelibrary.jar;"c: robot excution local scripts> echo" .... lib samplelibrary.jar;" .... lib lib samplelibrary.jar;"" .... lib samplelibrary.jar;" .... lib samplelibrary.jar;"c: robot excution local scripts> jybot -outputdir ............ output ........................................................ Impartation testsuites samplelibrarytestsuite.html[错误]解析'...... Imparination testsuites SamplelibraryTestestestestestestestestestestestestestestestestes.html'失败:数据源不存在。

任何建议都是对!

https://tutel.me/c/programming/questions/42384822/42384822/it ers ers when specifying the the the defined defined jjava library library library into 框架 日食 编辑

参考上述博客,它起作用了!!!

为什么要java?Robotframework是Python包装纸,您可以将Python与所有库一起使用。易于导入:

Library    your/python/file/path.py

您也可以在一个机器人文件中执行Python线

Evaluate    print("Hello word") 

顺便说一句,您可以制作Java关键字并将其导入机器人。教程在这里https://blog.codecentric.de/en/2012/06/robot-framework-tutorial-writing-writing-worting-word-liblaries-libraries-in-java/

最新更新