【发布时间】:2018-12-14 10:17:23
【问题描述】:
有没有办法为测试用例生成 Robot Framework 文档?
我可以使用 libdoc 成功地为关键字和库生成文档,但是当我尝试对仅包含测试用例的 .robot 文件执行相同操作时,我收到以下错误。
测试用例文件:
*** Settings ***
Documentation Suite documentation to appear on top of the html doc.
Resource ../Root.robot
Suite Setup Create Data
Suite Teardown Delete Data
Test Setup Go To Homepage
Test Teardown Close All Browsers
*** Test Cases ***
Test A
[Documentation] The test case documentation.
Do Something
在此文件上使用libdoc 时出错:
Try --help for usage information.
[ ERROR ] Error in file '/<path>Test.robot': Non-existing setting 'Test Setup'.
[ ERROR ] Error in file '/<path>Test.robot': Non-existing setting 'Test Teardown'.
[ ERROR ] Error in file '/<path>Test.robot': Non-existing setting 'Suite Setup'.
[ ERROR ] Error in file '/<path>Test.robot': Non-existing setting 'Suite Teardown'.
Resource file '/<path>Test.robot' contains a test case table which is not allowed.
是不是因为 libdoc 不支持设置和拆解?
【问题讨论】:
-
呃,我应该使用 TestDoc 而不是 LibDoc。谢谢@BryanOakley。
标签: robotframework