Skip to content

Commit 95acb0b

Browse files
committed
quantityShouldBeNotLessThanLimit: port to Robot Framework.
Addressed to #530 No functional changes.
1 parent 6ec19e3 commit 95acb0b

File tree

2 files changed

+6
-12
lines changed

2 files changed

+6
-12
lines changed

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

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@
4242
import static ru.mystamps.web.tests.fest.PageWithFormAssert.assertThat;
4343
import static ru.mystamps.web.validation.ValidationRules.MAX_SERIES_COMMENT_LENGTH;
4444
import static ru.mystamps.web.validation.ValidationRules.MAX_STAMPS_IN_SERIES;
45-
import static ru.mystamps.web.validation.ValidationRules.MIN_STAMPS_IN_SERIES;
4645

4746
import static org.fest.assertions.api.Assertions.assertThat;
4847

@@ -148,17 +147,6 @@ public void catalogNumbersShouldAcceptValidValues(String numbers, Object whateve
148147
assertThat(page).field("gibbonsNumbers").hasNoError();
149148
}
150149

151-
@Test(groups = "invalid", dependsOnGroups = "std")
152-
public void quantityShouldBeNotLessThanLimit() {
153-
page.fillQuantity(String.valueOf(MIN_STAMPS_IN_SERIES - 1));
154-
155-
page.submit();
156-
157-
assertThat(page)
158-
.field("quantity")
159-
.hasError(tr("javax.validation.constraints.Min.message", MIN_STAMPS_IN_SERIES));
160-
}
161-
162150
@Test(groups = "invalid", dependsOnGroups = "std")
163151
public void quantityShouldNotBeGreaterThanLimit() {
164152
page.fillQuantity(String.valueOf(MAX_STAMPS_IN_SERIES + 1));

src/test/robotframework/series/creation/validation.robot

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,12 @@ Create series with non-numeric quantity
1212
Submit Form id=add-series-form
1313
Element Text Should Be id=quantity.errors Invalid value
1414

15+
Create series with quantity that is less than 1
16+
[Documentation] Verify validation of too small quantity
17+
Input Text id=quantity 0
18+
Submit Form id=add-series-form
19+
Element Text Should Be id=quantity.errors Value must be greater than or equal to 1
20+
1521
*** Keywords ***
1622
Before Test Suite
1723
[Documentation] Login as admin and go to create series page

0 commit comments

Comments
 (0)