I'm trying to create a scenario where two users would access the application, so I could simulate a sold-out product when one user has it on the cart (more or less).
E.g.
Given user1 access website
Then user1 add a product to the cart
Here comes the user2 (not quite sure if I should use another Given or an And, the point here would be opening another window, and keep the window from user1 on hold).
Given user2 access website
Then user2 add a product to the cart
And user2 complete purchase
(Closing the window of user2)
Here the user1 would try to finish the purchase (back to user1 window)
Then user1 tries to finalize the purchase and gets a warning that product is no longer available
That is more of an idea than the actual flow, but the main point here is to have this "conflict" of empty inventory. I want the user1 to be able to add the product to the cart to later display a warning that the product is no longer available. So, I can't have the Scenario starting with an empty inventory because then the user1 won't even see the product to test against it.