robotframework-2.7.7.atest.robot.libdoc.cli.txt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of robotframework Show documentation
Show all versions of robotframework Show documentation
High level test automation framework
The newest version!
*** Settings ***
Force Tags regression pybot jybot
Resource libdoc_resource.txt
Test Template Run Libdoc And Verify Created Output File
*** Test Cases ***
Default format is got from output file extension
String ${OUTHTML} HTML String
String ${OUTXML} XML String path=${OUTXML}
Using --format overrides output file extension
-f XmL ${TESTDATADIR}/resource.txt ${OUTHTML} XML resource
--format hTmL BuiltIn ${OUTPREFIX}.xxx HTML BuiltIn path=${OUTPREFIX}.xxx
Override name and version
--name MyName --version 42 String ${OUTHTML} HTML MyName 42
-n MyName -v 42 -f xml BuiltIn ${OUTHTML} XML MyName 42
Relative path with Python libraries
[Template] NONE
${dir in libdoc exec dir}= Set Variable ${ROBOTPATH}/../TempDirInExecDir
Directory Should Not Exist ${dir in libdoc exec dir}
Create Directory ${dir in libdoc exec dir}
Create File ${dir in libdoc exec dir}/MyLibrary.py def my_keyword(): pass
Run Libdoc And Parse Output ${dir in libdoc exec dir}/MyLibrary.py
Name Should Be MyLibrary
Keyword Name Should Be 0 My Keyword
[Teardown] Remove Directory ${dir in libdoc exec dir} recursively
*** Keywords ***
Run Libdoc And Verify Created Output File
[Arguments] ${args} ${format} ${name} ${version}= ${path}=${OUTHTML}
${stdout} = Run Libdoc ${args}
Run Keyword ${format} Doc Should Have Been Created ${path} ${name} ${version}
Path to output should be in stdout ${path} ${stdout.rstrip()}
[Teardown] Remove Output Files
HTML Doc Should Have Been Created
[Arguments] ${path} ${name} ${version}
${libdoc}= Get File ${path}
Should Start With ${libdoc}