Skip to content

Commit 7533629

Browse files
committed
WhenAdminAddCategory.categoryName{En,Ru}ShouldReplaceRepeatedSpacesByOne: port to Robot Framework.
Addressed to #530 No functional changes.
1 parent 29c8230 commit 7533629

File tree

2 files changed

+8
-17
lines changed

2 files changed

+8
-17
lines changed

src/test/java/ru/mystamps/web/tests/cases/WhenAdminAddCategory.java

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,6 @@
3333

3434
public class WhenAdminAddCategory extends WhenAnyUserAtAnyPageWithForm<AddCategoryPage> {
3535

36-
private static final String TEST_CATEGORY_NAME_EN = "Space";
37-
private static final String TEST_CATEGORY_NAME_RU = "Космос";
38-
3936
@Value("${valid_admin_login}")
4037
private String validAdminLogin;
4138

@@ -81,20 +78,6 @@ public void categoryNameRuWithAllowedCharactersShouldBeAccepted() {
8178

8279
assertThat(page).field("nameRu").hasNoError();
8380
}
84-
85-
@Test(groups = "misc", dependsOnGroups = "std")
86-
public void categoryNameEnShouldReplaceRepeatedSpacesByOne() {
87-
page.addCategory("t3 st", TEST_CATEGORY_NAME_RU);
88-
89-
assertThat(page).field("name").hasValue("t3 st");
90-
}
91-
92-
@Test(groups = "misc", dependsOnGroups = "std")
93-
public void categoryNameRuShouldReplaceRepeatedSpacesByOne() {
94-
page.addCategory(TEST_CATEGORY_NAME_EN, "т3 ст");
95-
96-
assertThat(page).field("nameRu").hasValue("т3 ст");
97-
}
9881

9982
@Override
10083
protected void checkServerResponseCode() {

src/test/robotframework/category/creation/misc.robot

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,14 @@ Category name should be stripped from leading and trailing spaces
1515
Textfield Value Should Be id=name t3st
1616
Textfield Value Should Be id=nameRu т3ст
1717

18+
Category name should be modified by replacing multiple spaces by one
19+
[Documentation] Verify replacing of repeating spaces from name
20+
Input Text id=name t3${SPACE * 2}st
21+
Input Text id=nameRu т3${SPACE * 2}ст
22+
Submit Form id=add-category-form
23+
Textfield Value Should Be id=name t3 st
24+
Textfield Value Should Be id=nameRu т3 ст
25+
1826
*** Keywords ***
1927
Before Test Suite
2028
[Documentation] Open browsers, register fail hook and login as admin

0 commit comments

Comments
 (0)