Skip to content

Commit

Permalink
add AMPS
Browse files Browse the repository at this point in the history
  • Loading branch information
zsomborfoldi committed Nov 28, 2024
1 parent f0339d5 commit 0cc4f16
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 4 deletions.
1 change: 1 addition & 0 deletions ebl/common/domain/project.py
Original file line number Diff line number Diff line change
Expand Up @@ -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)
2 changes: 1 addition & 1 deletion ebl/tests/factories/fragment.py
Original file line number Diff line number Diff line change
Expand Up @@ -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)

Expand Down
2 changes: 1 addition & 1 deletion ebl/tests/fragmentarium/test_dtos.py
Original file line number Diff line number Diff line change
Expand Up @@ -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": [],
Expand Down
3 changes: 2 additions & 1 deletion ebl/tests/fragmentarium/test_fragment_repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -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(
Expand Down
2 changes: 1 addition & 1 deletion ebl/tests/fragmentarium/test_fragments_search_route.py
Original file line number Diff line number Diff line change
Expand Up @@ -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 = [
Expand Down

0 comments on commit 0cc4f16

Please sign in to comment.