From cdcd95951f6d5edf227aacdaff9a08c269692b67 Mon Sep 17 00:00:00 2001 From: Andrea Bollini Date: Fri, 19 Jan 2024 10:47:44 +0100 Subject: [PATCH] DSC-1458 fix test to reflect the fact that enhanced metadata are always included also for external authors --- .../app/bulkimport/service/BulkImportWorkbookBuilderIT.java | 4 ++-- .../src/test/java/org/dspace/harvest/OAIHarvesterIT.java | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dspace-api/src/test/java/org/dspace/app/bulkimport/service/BulkImportWorkbookBuilderIT.java b/dspace-api/src/test/java/org/dspace/app/bulkimport/service/BulkImportWorkbookBuilderIT.java index a7006b6a8a1..9de061db8f9 100644 --- a/dspace-api/src/test/java/org/dspace/app/bulkimport/service/BulkImportWorkbookBuilderIT.java +++ b/dspace-api/src/test/java/org/dspace/app/bulkimport/service/BulkImportWorkbookBuilderIT.java @@ -209,7 +209,7 @@ public void testWorkbookBuildingFromItemDtos() throws Exception { Item firstItem = getItemFromMessage(handler.getInfoMessages().get(7)); assertThat(firstItem, notNullValue()); - assertThat(firstItem.getMetadata(), hasSize(14)); + assertThat(firstItem.getMetadata(), hasSize(16)); assertThat(firstItem.getMetadata(), hasItems( with("dc.title", "Test Publication"), with("dc.date.issued", "2020/02/15"), @@ -227,7 +227,7 @@ public void testWorkbookBuildingFromItemDtos() throws Exception { Item secondItem = getItemFromMessage(handler.getInfoMessages().get(10)); assertThat(secondItem, notNullValue()); - assertThat(secondItem.getMetadata(), hasSize(14)); + assertThat(secondItem.getMetadata(), hasSize(16)); assertThat(secondItem.getMetadata(), hasItems( with("dc.title", "Second Publication"), with("dc.date.issued", "2022/02/15"), diff --git a/dspace-api/src/test/java/org/dspace/harvest/OAIHarvesterIT.java b/dspace-api/src/test/java/org/dspace/harvest/OAIHarvesterIT.java index e58788104aa..c180b77dc26 100644 --- a/dspace-api/src/test/java/org/dspace/harvest/OAIHarvesterIT.java +++ b/dspace-api/src/test/java/org/dspace/harvest/OAIHarvesterIT.java @@ -769,7 +769,7 @@ public void testRunHarvestWithPublicationAndThenPerson() throws Exception { Item publication = publications.get(0); List values = publication.getMetadata(); - assertThat(values, hasSize(17)); + assertThat(values, hasSize(19)); assertThat(values, hasItems(with("dc.title", "Test Publication"))); assertThat(values, hasItems(with("dc.type", "Controlled Vocabulary for Resource Type Genres::text"))); @@ -859,7 +859,7 @@ public void testRunHarvestWithPersonAndThenPublication() throws Exception { Item person = findItemByOaiID("oai:test-harvest:Persons/123", personCollection); List values = person.getMetadata(); - assertThat(values, hasSize(12)); + assertThat(values, hasSize(14)); assertThat(values, hasItems(with("dc.title", "Manghi, Paolo"))); assertThat(values, hasItems(with("cris.sourceId", "test-harvest::123"))); assertThat(values, hasItems(with("dspace.entity.type", "Person")));