Skip to content

Commit 17ba368

Browse files
committed
tuning test data
Signed-off-by: Pekka Klärck <peke@iki.fi>
1 parent 29d201e commit 17ba368

3 files changed

Lines changed: 5 additions & 12 deletions

File tree

login_tests/invalid_login.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,25 +4,24 @@ Documentation A test suite containing tests related to invalid login.
44
... These tests are data-driven by they nature. They use a single
55
... keyword, specified with Test Template setting, that is called
66
... with different arguments to cover different scenarios.
7+
...
8+
... This suite also demonstrates using setups and teardowns in
9+
... different levels.
710
Suite Setup Open Browser To Login Page
811
Suite Teardown Close Browser
912
Test Setup Go To Login Page
1013
Test Template Login With Invalid Credentials Should Fail
1114
Resource resource.txt
1215

13-
1416
*** Test Cases *** User Name Password
15-
1617
Invalid Username invalid ${VALID PASSWORD}
1718
Invalid Password ${VALID USER} invalid
1819
Invalid Username And Password invalid whatever
1920
Empty Username ${EMPTY} ${VALID PASSWORD}
2021
Empty Password ${VALID USER} ${EMPTY}
2122
Empty Username And Password ${EMPTY} ${EMPTY}
2223

23-
2424
*** Keywords ***
25-
2625
Login With Invalid Credentials Should Fail
2726
[Arguments] ${username} ${password}
2827
Input Username ${username}

login_tests/resource.txt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@ Documentation A resource file with reusable keywords and variables.
55
... domain specific language.
66
Library Selenium2Library
77

8-
98
*** Variables ***
10-
119
${SERVER} localhost:7272
1210
${BROWSER} Firefox
1311
${DELAY} 0
@@ -17,9 +15,7 @@ ${LOGIN URL} http://${SERVER}/
1715
${WELCOME URL} http://${SERVER}/welcome.html
1816
${ERROR URL} http://${SERVER}/error.html
1917

20-
2118
*** Keywords ***
22-
2319
Open Browser To Login Page
2420
Open Browser ${LOGIN URL} ${BROWSER}
2521
Maximize Browser Window

login_tests/valid_login.txt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,11 @@ Documentation A test suite with a single test for valid login.
55
... the imported resource file.
66
Resource resource.txt
77

8-
98
*** Test Cases ***
10-
119
Valid Login
1210
Open Browser To Login Page
13-
Input Username ${VALID USER}
14-
Input Password ${VALID PASSWORD}
11+
Input Username demo
12+
Input Password mode
1513
Submit Credentials
1614
Welcome Page Should Be Open
1715
[Teardown] Close Browser

0 commit comments

Comments
 (0)