BETTERZON-99: Adding some basic cucumber tests (#45)

This commit is contained in:
Patrick
2021-05-13 16:42:55 +02:00
committed by GitHub
parent 0be394fc1d
commit 5cc91654c3
8 changed files with 223 additions and 146 deletions
@@ -1,28 +1,28 @@
Feature: Price Alarms
Scenario: Show a list of price alarms
Given the user is on the landing page
And the user is logged in
And the user has at least 1 price alarm set
When the user clicks on the profile icon
Then the profile details popup should open
When the user clicks on price alarms
Then the price alarm list should open
And the price alarm list should contain at least 1 entry
And the price alarm list should contain a maximum of 20 entries per page
Scenario: Show a list of price alarms
Given the user is on the landing page
And the user is logged in
And the user has at least 1 price alarm set
When the user clicks on the profile icon
Then the profile details popup should open
When the user clicks on price alarms
Then the price alarm list should open
And the price alarm list should contain at least 1 entry
And the price alarm list should contain a maximum of 20 entries per page
Scenario: Remove a price alarm
Given the user is on the price alarm list page
And the user is logged in
When the user clicks on the "remove" button next to a price alarm
Then a popup should open asking the user to confirm the removal
When the user confirms the removal of the price alarm
Then the price alarm should be removed from the database
Scenario: Remove a price alarm
Given the user is on the price alarm list page
And the user is logged in
When the user clicks on the "remove" button next to a price alarm
Then a popup should open asking the user to confirm the removal
When the user confirms the removal of the price alarm
Then the price alarm should be removed from the database
Scenario: Edit a price alarm
Given the user is on the price alarm list page
And the user is logged in
When the user clicks on the "edit" button next to a price alarm
Then a popup should open where the user can edit the alarm
When the user clicks on the "save changes" button
Then the price alarm should be updated in the database
Scenario: Edit a price alarm
Given the user is on the price alarm list page
And the user is logged in
When the user clicks on the "edit" button next to a price alarm
Then a popup should open where the user can edit the alarm
When the user clicks on the "save changes" button
Then the price alarm should be updated in the database
@@ -1,26 +1,26 @@
Feature: Search a Product
Scenario: User searches for unknown product
Given the user is on the landing page
When the user enters the search term "iPhone 13" and clicks search
Then the user should see the error page "No products found"
Scenario: User searches for unknown product
Given the user is on the landing page
When the user enters the search term "iPhone 13" and clicks search
Then the user should see the error page "No products found"
Scenario: User is not logged in, searches for known product
Given the user is on the landing page
And the user is not logged in
When the user enters the search term "iPhone 12" and clicks search
Then the user should see a list of products
When the user clicks on the first product
Then the user should see the product detail page
And the set price alarm box should show "Log in to continue"
Scenario: User is not logged in, searches for known product
Given the user is on the landing page
And the user is not logged in
When the user enters the search term "iPhone 12" and clicks search
Then the user should see a list of products
When the user clicks on the first product
Then the user should see the product detail page
And the set price alarm box should show "Log in to continue"
Scenario: User is logged in, searches for known product
Given the user is on the landing page
And the user is logged in
When the user enters the search term "iPhone 12" and clicks search
Then the user should see a list of products
When the user clicks on the first product
Then the user should see the product detail page
And the set price alarm box should show "Set price alarm"
When the user sets a price alarm
Then the user should receive an email confirming the price alarm
Scenario: User is logged in, searches for known product
Given the user is on the landing page
And the user is logged in
When the user enters the search term "iPhone 12" and clicks search
Then the user should see a list of products
When the user clicks on the first product
Then the user should see the product detail page
And the set price alarm box should show "Set price alarm"
When the user sets a price alarm
Then the user should receive an email confirming the price alarm