robotframework基本语法一

*** Settings ***
Library     OperatingSystem
 #Settings:导入测试库,资源文件,变量文件,为创建测试套件和test cases定义元数据
*** Variables ***
# 定义变量
${MESSAGE}  Hello,world!
*** Test Cases ***
My Test
# 创建测试用例
    [Documentation]     Example test
    log  ${message}}

Another Test
    should be equal     ${message}  Hello,world!

*** Keywords ***
# 创建用户关键字
My Keyword
    [Arguments]  ${path}
    DIRECTORY SHOULD EXIST  ${path}

 

posted @ 2018-07-02 13:42  jiyanjiao  阅读(2736)  评论(0编辑  收藏  举报