MageTest / BehatMage

Behat for Magento
MIT License
85 stars 31 forks source link

Don't add stock_data attribute if is_in_stock was not specified #40

Closed jon-acker closed 10 years ago

jon-acker commented 10 years ago

"Given the following products exist" step was causing the stock_data attribute to be created regardless of whether is_in_stock was specified in the table. This in turn cause an empty stock_data attribute to override the default attribute of stock_data (with is_in_stock = 1, qty = 99999). Now stock_data is taken from the table if is_in_stock/qty are provided, and uses defaults correctly if not. Also, user should be prompted to provide qty if is_in_stock is specified.