voronianski/flux-comparison app spec(unofficail).
- When: Add to Cart "iPad 4 Mini - €500.01" * 1
- Then: "iPad 4 Mini - €500.01 x 1" in your cart.
- When: Checkout the cart
- Then: Show
"YOU BOUGHT:" Array [ Object ]
in Console.
- Then: Show
Array [ Object ]
is following:
[
{
"id": 1,
"title": "iPad 4 Mini",
"price": 500.01,
"inventory": 1, // because a calling sequence is productStore -> cartStore.
"image": "../common/assets/ipad-mini.png",
"quantity": 1
}
]
The calling sequence of stores should be productStore -> cartStore. So, CartStore wait for productStore.
- When: Add to Cart "iPad 4 Mini - €500.01" * 1
- Then: "iPad 4 Mini - €500.01" is Sold Out
- Then: "iPad 4 Mini - €500.01 x 1" in your cart.
- When: Add to Cart "H&M T-Shirt White - €10.99" * 1
- When: Add to Charli XCX - Sucker CD - €19.99" * 1
- Then: Your cart fill with
iPad 4 Mini - €500.01 x 1 H&M T-Shirt White - €10.99 x 1 Charli XCX - Sucker CD - €19.99 x 1 Total: €530.99
- When: Checkout the cart
- Then: show `"YOU BOUGHT:" Array [ Object, Object, Object ]` in Console.
```js
[
{
"id": 1,
"title": "iPad 4 Mini",
"price": 500.01,
"inventory": 0,
"image": "../common/assets/ipad-mini.png",
"quantity": 1
},
{
"id": 2,
"title": "H&M T-Shirt White",
"price": 10.99,
"inventory": 9,
"image": "../common/assets/t-shirt.png",
"quantity": 1
},
{
"id": 3,
"title": "Charli XCX - Sucker CD",
"price": 19.99,
"inventory": 4,
"image": "../common/assets/sucker.png",
"quantity": 1
}
]