Skip to content

Commit

Permalink
Merge branch 'refactor-cc-service-unit-tests-#308' into refactor-cc-e…
Browse files Browse the repository at this point in the history
…2e-tests-#314
  • Loading branch information
joelvdavies committed Jul 24, 2024
2 parents 987e27e + e9b71b6 commit 61a6c51
Showing 1 changed file with 0 additions and 19 deletions.
19 changes: 0 additions & 19 deletions test/unit/services/test_catalogue_category.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
CATALOGUE_CATEGORY_POST_DATA_LEAF_NO_PARENT_NO_PROPERTIES,
CATALOGUE_CATEGORY_POST_DATA_NON_LEAF_NO_PARENT_NO_PROPERTIES_A,
CATALOGUE_CATEGORY_POST_DATA_NON_LEAF_NO_PARENT_NO_PROPERTIES_B,
CATALOGUE_CATEGORY_PROPERTY_DATA_BOOLEAN_MANDATORY,
CATALOGUE_CATEGORY_PROPERTY_DATA_NUMBER_NON_MANDATORY_WITH_MM_UNIT,
UNIT_IN_DATA_MM,
)
Expand All @@ -27,7 +26,6 @@
from inventory_management_system_api.core.custom_object_id import CustomObjectId
from inventory_management_system_api.core.exceptions import (
ChildElementsExistError,
DuplicateCatalogueCategoryPropertyNameError,
LeafCatalogueCategoryError,
MissingRecordError,
)
Expand Down Expand Up @@ -297,23 +295,6 @@ def test_create_with_properties(self):
self.call_create()
self.check_create_success()

def test_create_with_duplicate_properties(self):
"""Test creating a catalogue category with properties."""

self.mock_create(
{
**CATALOGUE_CATEGORY_POST_DATA_NON_LEAF_NO_PARENT_NO_PROPERTIES_A,
"properties": [
CATALOGUE_CATEGORY_PROPERTY_DATA_BOOLEAN_MANDATORY,
CATALOGUE_CATEGORY_PROPERTY_DATA_BOOLEAN_MANDATORY,
],
},
)
self.call_create_expecting_error(DuplicateCatalogueCategoryPropertyNameError)
self.check_create_failed_with_exception(
f"Duplicate property name: {CATALOGUE_CATEGORY_PROPERTY_DATA_BOOLEAN_MANDATORY['name']}"
)

def test_create_with_properties_with_non_existent_unit_id(self):
"""Test creating a catalogue category with properties with a non-existent unit id."""

Expand Down

0 comments on commit 61a6c51

Please sign in to comment.