Преглед изворни кода

Change basket quantity error message in tests as well.

master
Joey Jurjens пре 2 година
родитељ
комит
72e60e9f95
2 измењених фајлова са 2 додато и 2 уклоњено
  1. 1
    1
      tests/functional/test_basket.py
  2. 1
    1
      tests/integration/basket/test_forms.py

+ 1
- 1
tests/functional/test_basket.py Прегледај датотеку

@@ -515,6 +515,6 @@ class BasketFormSetTests(WebTestCase):
515 515
         self.assertEqual(response.status_code, 200)
516 516
         self.assertFalse(response.context['formset'].forms[0].is_valid())
517 517
         self.assertIn(
518
-            "can be bought which has been exceeded because you have multiple lines of the same product.",
518
+            "Available stock is only %s, which has been exceeded because multiple lines contain the same product." % 2,
519 519
             str(response.context['formset'].forms[0].errors)
520 520
         )

+ 1
- 1
tests/integration/basket/test_forms.py Прегледај датотеку

@@ -154,7 +154,7 @@ class TestBasketLineForm(TestCase):
154 154
         )
155 155
         self.assertFalse(form.is_valid())
156 156
         self.assertIn(
157
-            "can be bought which has been exceeded because you have multiple lines of the same product.",
157
+            "Available stock is only %s, which has been exceeded because multiple lines contain the same product." % 2,
158 158
             str(form.errors)
159 159
         )
160 160
 

Loading…
Откажи
Сачувај