Files
mozo-backend/spec/acceptance/users/order_a_product.feature
T

39 lines
1.8 KiB
Gherkin

Feature: Ordering a product as a user
@javascript
Scenario: Happy flow
Given There is an open supplier with a menu
And I am signed in as a user
And I am on the user homepage
When the user scans a table QR code
And the user clicks on the order 'Heineken beer' twice
Then the user order 'Heineken beer' should be in the order list with price
And the user order total should not be visible for only one order
When the user clicks on the order product button 'Apple pie'
Then the user order total should be visible with the correct total price
When the user clicks on the user order button
Then the user should be redirected to the user order overview page
And the user order should be created as a new order
When the user order gets marked as being in process
Then the user order should get feedback of being in process
When the user order gets marked as being delivered
Then the user order should get feedback of being delivered
When the user orders list gets closed
Then the user should be redirected to the archived list path
@javascript
Scenario: Resetting an active order
Given There is an open supplier with a menu
And I am signed in as a user
And I am on the user homepage
When the user scans a table QR code
And the user clicks on the order 'Heineken beer' twice
And the user clicks on the order product button 'Apple pie'
And the user clicks on the clear order for the last order button
And the user clicks on the clear order for the last order button
Then the user should see an empty active order panel
And the user clicks on the order 'Heineken beer' twice
And the user clicks on the user order button
Then an order with 2 products 'Heineken beer' should have been created
And no order for the product 'Apple pie' should have been created