File tree Expand file tree Collapse file tree 5 files changed +27
-81
lines changed
main/resources/test/spring
java/ru/mystamps/web/tests
robotframework/account/authentication Expand file tree Collapse file tree 5 files changed +27
-81
lines changed Original file line number Diff line number Diff line change 3
3
#
4
4
5
5
# this user should always exist
6
+ # (used at least by account/authentication/logic.robot)
6
7
valid_user_login = coder
7
8
valid_user_name = Test Suite
8
9
valid_user_password = test
Original file line number Diff line number Diff line change 13
13
</classes >
14
14
</test >
15
15
16
- <test name =" When anonymous user authenticates" >
17
- <classes >
18
- <class name =" ru.mystamps.web.tests.cases.WhenAnonymousUserAuthenticates" />
19
- </classes >
20
- </test >
21
-
22
16
<test name =" When user logs out" >
23
17
<classes >
24
18
<class name =" ru.mystamps.web.tests.cases.WhenUserLogsOut" />
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 34
34
@ RequiredArgsConstructor (access = PROTECTED )
35
35
public abstract class AbstractPage {
36
36
37
- // CheckStyle: ignore LineLength for next 2 lines
37
+ // CheckStyle: ignore LineLength for next 1 line
38
38
private static final String LOGOUT_BUTTON_LOCATOR = "//form[@id=\" logout-form\" ]/input[@type=\" submit\" ]" ;
39
- private static final String USER_BAR_ENTRIES_LOCATOR = "//*[@id=\" user_bar\" ]//li/a | //*[@id=\" user_bar\" ]//li//input[not(@type=\" hidden\" )]" ;
40
39
private static final String A_HREF_LOCATOR = "//a[@href=\" %s\" ]" ;
41
40
42
41
protected final WebDriver driver ;
@@ -78,11 +77,6 @@ protected boolean pageUrlChanged() {
78
77
return !driver .getCurrentUrl ().equals (getFullUrl ());
79
78
}
80
79
81
- public List <String > getUserBarEntries () {
82
- List <WebElement > entries = getElementsByXPath (USER_BAR_ENTRIES_LOCATOR );
83
- return WebElementUtils .convertToListWithText (entries );
84
- }
85
-
86
80
public boolean linkWithLabelExists (String label ) {
87
81
return getLinkByText (label ) != null ;
88
82
}
Original file line number Diff line number Diff line change
1
+ *** Settings ***
2
+ Documentation Verify account authentication scenarios
3
+ Library SeleniumLibrary
4
+ Resource ../../auth.steps.robot
5
+ Suite Setup Before Test Suite
6
+ Suite Teardown After Test Suite
7
+ Force Tags account authentication logic
8
+
9
+ *** Test Cases ***
10
+ Successful authentication
11
+ Input Text id=login coder
12
+ Input Text id=password test
13
+ Submit Form id=auth-account-form
14
+ Location Should Be ${SITE_URL } /
15
+ Page Should Contain Link Test Suite
16
+ Page Should Contain Button value=Sign out
17
+
18
+ *** Keywords ***
19
+ Before Test Suite
20
+ Open Browser ${SITE_URL } /account/auth ${BROWSER }
21
+ Register Keyword To Run On Failure Log Source
22
+
23
+ After Test Suite
24
+ Log Out
25
+ Close Browser
You can’t perform that action at this time.
0 commit comments