def apply_discount(line, discount, quantity):
 line.discount(discount, quantity, incl_tax=False)

def apply_discount ( line , discount , quantity ) : line . discount ( discount , quantity , incl_tax = False )
apply a given discount to the passed basket .