Commit cd727d8d authored by MOREAU Ulysse's avatar MOREAU Ulysse

simplify tests

parent 2c9471cb
......@@ -773,7 +773,7 @@ class OrderTest(PaymentTestCase, OrderItemTestCase):
self.assertFalse(pack_with_illegal_children.contains_illegal_items)
self.assertFalse(legal_item.contains_illegal_items)
items_in_order = [oi.item for oi in self.order.items.all()]
previous_items_in_order = [oi.item for oi in self.order.items.all()]
deleted_count = self.order.clean_illegal_items()
self.assertEqual(deleted_count, 0)
......@@ -782,10 +782,7 @@ class OrderTest(PaymentTestCase, OrderItemTestCase):
items_in_order = [oi.item for oi in self.order.items.all()]
self.assertTrue(hidden_item in items_in_order)
self.assertTrue(ood_item in items_in_order)
self.assertTrue(pack_with_illegal_children in items_in_order)
self.assertTrue(legal_item in items_in_order)
self.assertEqual(previous_items_in_order, items_in_order)
def test_delete_illegal_items_on_unordered_order(self) -> None:
hidden_item = self.create_item()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment