|
| 1 | +@managing_inventory |
| 2 | +Feature: Filtering products |
| 3 | + In order to find a product I am into |
| 4 | + As a Customer |
| 5 | + I want to be able to filter products by specific criteria |
| 6 | + |
| 7 | + Background: |
| 8 | + Given the store operates on a channel named "Web-US" in "USD" currency |
| 9 | + And there are 15 t-shirts in the store |
| 10 | + And 5 of these products are priced between "$10" and "$15" |
| 11 | + And 10 of these products are priced between "$15" and "$35" |
| 12 | + And these "products" have "size" option |
| 13 | + And 3 of these products have "size" option with "S" value |
| 14 | + And 5 of these products have "size" option with "M" value |
| 15 | + And 7 of these products have "size" option with "M" value |
| 16 | + And these "products" have "color" attribute |
| 17 | + And 3 of these products have "color" attribute with "Red" value |
| 18 | + And 5 of these products have "color" attribute with "Green" value |
| 19 | + And 7 of these products have "color" attribute with "Blue" value |
| 20 | + |
| 21 | + @ui |
| 22 | + Scenario: Filtering products by name |
| 23 | + When I go to the shop products page |
| 24 | + And I search the products by "shirt" phase |
| 25 | + Then I should see 9 products on the first page |
| 26 | + And I should see 6 products on the second page |
| 27 | + |
| 28 | + @ui |
| 29 | + Scenario: Filtering products by options |
| 30 | + When I go to the shop products page |
| 31 | + And I filter products by "S" "Size" option |
| 32 | + And I filter products by "M" "Size" option |
| 33 | + Then I should see 8 products on the page |
| 34 | + |
| 35 | + @ui |
| 36 | + Scenario: Filtering products by attributes |
| 37 | + When I go to the shop products page |
| 38 | + And I filter products by "Red" "Color" attribute |
| 39 | + And I filter products by "Green" "Color" attribute |
| 40 | + Then I should see 8 products on the page |
| 41 | + |
| 42 | + @ui |
| 43 | + Scenario: Filtering products by price |
| 44 | + When I go to the shop products page |
| 45 | + And I filter product price between 10 and 15 |
| 46 | + Then I should see 5 products on the page |
| 47 | + |
| 48 | + @ui |
| 49 | + Scenario: Changing limit to from 9 to 18 |
| 50 | + Given there are 40 more products in the store |
| 51 | + When I go to the products page |
| 52 | + And I change the limit to 18 |
| 53 | + Then I should see 18 products on the first page |
| 54 | + And I should see 18 products on the second page |
| 55 | + And I should see 9 products on the third page |
| 56 | + |
| 57 | + @ui |
| 58 | + Scenario: Changing limit to from 9 to 36 |
| 59 | + Given there are 40 more products in the store |
| 60 | + When I go to the products page |
| 61 | + And I change the limit to 36 |
| 62 | + Then I should see 36 products on the first page |
| 63 | + And I should see 9 products on the second page |
0 commit comments