All released versions are hosted on the Python Package Index. You can install this package with following command.
pip install stories
stories
provide a simple way to define a complex business scenario that include many processing steps.
from stories import story, argument, Success
class PurchaseProduct:
@story
@argument('user')
@argument('product')
@argument('shipment_details')
def purchase(I):
I.create_order
I.calculate_price
I.request_payment
I.notify_user
def create_order(self, ctx):
return Success(order=Order.objects.create(user=ctx.user, product=ctx.product))
def calculate_price(self, ctx):
return Success(...
This code style allow you clearly separate actual business scenario from implementation details.
Dependencies library is offered under the two clause BSD license.