robotframework-seleniumlibrary

==========================
selenium:https://pypi.org/simple/selenium/
selenium-3.8.0.tar.gz

robotframework-seleniumlibrary:https://pypi.org/simple/robotframework-seleniumlibrary/
robotframework-seleniumlibrary-3.2.0.tar.gz

SeleniumLibrary

*** Settings ***
Documentation     Simple example using SeleniumLibrary.
Library           SeleniumLibrary

*** Variables ***
${LOGIN URL}      http://localhost:7272
${BROWSER}        Chrome

*** Test Cases ***
Valid Login
    Open Browser To Login Page
    Input Username    demo
    Input Password    mode
    Submit Credentials
    Welcome Page Should Be Open
    [Teardown]    Close Browser

*** Keywords ***
Open Browser To Login Page
    Open Browser    ${LOGIN URL}    ${BROWSER}
    Title Should Be    Login Page

Input Username
    [Arguments]    ${username}
    Input Text    username_field    ${username}

Input Password
    [Arguments]    ${password}
    Input Text    password_field    ${password}

Submit Credentials
    Click Button    login_button

Welcome Page Should Be Open
    Title Should Be    Welcome Page

猜你喜欢

转载自blog.csdn.net/baidu_28126759/article/details/84563862
今日推荐