diff --git a/ebl/common/domain/project.py b/ebl/common/domain/project.py index fd082ff53..e5c4a06f6 100644 --- a/ebl/common/domain/project.py +++ b/ebl/common/domain/project.py @@ -4,3 +4,4 @@ class ResearchProject(NamedEnumWithParent): CAIC = ("Cuneiform Artefacts of Iraq in Context", "CAIC", None) ALU_GENEVA = ("Edition of the Omen Series Summa Alu", "aluGeneva", None) + AMPS = ("Ancient Mesopotamian Priestly Scholasticism", "AMPS", None) diff --git a/ebl/tests/factories/fragment.py b/ebl/tests/factories/fragment.py index 67c3c45a3..fdcdfd7de 100644 --- a/ebl/tests/factories/fragment.py +++ b/ebl/tests/factories/fragment.py @@ -234,7 +234,7 @@ class Meta: introduction = Introduction("text", (StringPart("text"),)) notes = Notes("notes", (StringPart("notes"),)) external_numbers = factory.SubFactory(ExternalNumbersFactory) - projects = (ResearchProject.CAIC,) + projects = (ResearchProject.CAIC, ResearchProject.ALU_GENEVA, ResearchProject.AMPS) archaeology = factory.SubFactory(ArchaeologyFactory) colophon = factory.SubFactory(ColophonFactory) diff --git a/ebl/tests/fragmentarium/test_dtos.py b/ebl/tests/fragmentarium/test_dtos.py index 78fe42418..5b33e2c65 100644 --- a/ebl/tests/fragmentarium/test_dtos.py +++ b/ebl/tests/fragmentarium/test_dtos.py @@ -113,7 +113,7 @@ def expected_dto(lemmatized_fragment, has_photo): "externalNumbers": ExternalNumbersSchema().dump( lemmatized_fragment.external_numbers ), - "projects": [ResearchProject["CAIC"].abbreviation], + "projects": [ResearchProject["CAIC", "aluGeneva", "AMPS"].abbreviation], "archaeology": ArchaeologySchema().dump(lemmatized_fragment.archaeology), "colophon": ColophonSchema().dump(lemmatized_fragment.colophon), "authorizedScopes": [], diff --git a/ebl/tests/fragmentarium/test_fragment_repository.py b/ebl/tests/fragmentarium/test_fragment_repository.py index 892e2df79..7ff31eb28 100644 --- a/ebl/tests/fragmentarium/test_fragment_repository.py +++ b/ebl/tests/fragmentarium/test_fragment_repository.py @@ -1084,11 +1084,12 @@ def test_query_genres(fragment_repository, query, expected): [ ("CAIC", [0]), ("aluGeneva", [1]), + ("AMPS", [2]), (None, [0, 1]), ], ) def test_query_project(fragment_repository, query, expected): - projects = [ResearchProject.CAIC, ResearchProject.ALU_GENEVA] + projects = [ResearchProject.CAIC, ResearchProject.ALU_GENEVA, ResearchProject.AMPS] fragments = [ FragmentFactory.build( diff --git a/ebl/tests/fragmentarium/test_fragments_search_route.py b/ebl/tests/fragmentarium/test_fragments_search_route.py index 4744b06ae..9b1eea154 100644 --- a/ebl/tests/fragmentarium/test_fragments_search_route.py +++ b/ebl/tests/fragmentarium/test_fragments_search_route.py @@ -387,7 +387,7 @@ def test_search_script_period(client, fragmentarium, params, expected): @pytest.mark.parametrize( "project", - [ResearchProject.CAIC, ResearchProject.ALU_GENEVA], + [ResearchProject.CAIC, ResearchProject.ALU_GENEVA, ResearchProject.AMPS], ) def test_search_project(client, fragmentarium, project): fragments = [