diff --git a/src/backend/InvenTree/stock/test_api.py b/src/backend/InvenTree/stock/test_api.py index 4299cfa83c..e034c8dd2d 100644 --- a/src/backend/InvenTree/stock/test_api.py +++ b/src/backend/InvenTree/stock/test_api.py @@ -2409,7 +2409,10 @@ class StocktakeTest(StockAPITestCase): {'items': [{'pk': item_a.pk, 'quantity': 1}], 'location': structural.pk}, expected_code=400, ) - self.assertIn('does not exist', str(response.data['location'])) + self.assertIn( + 'Structural locations cannot be assigned stock items', + str(response.data['location']), + ) class StockItemDeletionTest(StockAPITestCase):