summaryrefslogtreecommitdiff
path: root/archaeological_warehouse
diff options
context:
space:
mode:
Diffstat (limited to 'archaeological_warehouse')
-rw-r--r--archaeological_warehouse/tests.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/archaeological_warehouse/tests.py b/archaeological_warehouse/tests.py
index c8e16a50c..e61afea49 100644
--- a/archaeological_warehouse/tests.py
+++ b/archaeological_warehouse/tests.py
@@ -36,6 +36,7 @@ from ishtar_common.tests import (
COMMON_FIXTURES,
create_user,
create_superuser,
+ StatisticsTest
)
from ishtar_common.models import IshtarSiteProfile
@@ -331,6 +332,24 @@ class SerializationTest(GenericSerializationTest, FindInit, TestCase):
)
+class ContainerSearchTest(TestCase, StatisticsTest):
+ fixtures = WAREHOUSE_FIXTURES
+ SEARCH_URL = "get-container"
+ MODEL = models.Container
+
+ def setUp(self):
+ IshtarSiteProfile.objects.get_or_create(slug="default", active=True)
+ self.username, self.password, self.user = create_superuser()
+ ct1 = models.ContainerType.objects.order_by("id").all()[0]
+ self.main_warehouse = models.Warehouse.objects.create(
+ name="Main", warehouse_type=models.WarehouseType.objects.all()[0]
+ )
+ self.container_1 = models.Container.objects.create(
+ reference="1", container_type=ct1,
+ location=self.main_warehouse
+ )
+
+
class WarehouseWizardCreationTest(WizardTest, FindInit, TestCase):
fixtures = WAREHOUSE_FIXTURES
url_name = "warehouse_creation"