Remove positivity constraint in apply_voucher

This commit is contained in:
Raphael Michel
2019-12-12 12:02:12 +01:00
parent 8a17fedaa6
commit 3da79ad36b
2 changed files with 4 additions and 0 deletions

View File

@@ -1827,6 +1827,7 @@ class CartTest(CartTestMixin, TestCase):
assert cp2.voucher == v2
assert cp2.price == Decimal('150.00')
"""
def test_voucher_apply_only_positive(self):
with scopes_disabled():
cp1 = CartPosition.objects.create(
@@ -1849,6 +1850,7 @@ class CartTest(CartTestMixin, TestCase):
cp2.refresh_from_db()
assert cp1.voucher is None
assert cp2.voucher is None
"""
def test_voucher_apply_expired(self):
with scopes_disabled():