From ce1546f96f57466f769fbc300f1b39e0aff8fd68 Mon Sep 17 00:00:00 2001 From: Juha Luoma Date: Fri, 19 Dec 2025 12:34:31 +0200 Subject: [PATCH] Add check in authenrichment that auth record contains getAlternativeNames method --- .../Base/Enrichment/AuthEnrichment.php | 5 + .../Base/Enrichment/AuthEnrichmentTest.php | 48 +- .../Base/record/forward_authority_1.xml | 1174 +++++++++++++++++ tests/fixtures/Base/record/marc_auth_2.xml | 17 + 4 files changed, 1235 insertions(+), 9 deletions(-) create mode 100644 tests/fixtures/Base/record/forward_authority_1.xml create mode 100644 tests/fixtures/Base/record/marc_auth_2.xml diff --git a/src/RecordManager/Base/Enrichment/AuthEnrichment.php b/src/RecordManager/Base/Enrichment/AuthEnrichment.php index ffa639ef..0675deb3 100644 --- a/src/RecordManager/Base/Enrichment/AuthEnrichment.php +++ b/src/RecordManager/Base/Enrichment/AuthEnrichment.php @@ -37,6 +37,8 @@ use RecordManager\Base\Utils\Logger; use RecordManager\Base\Utils\MetadataUtils; +use function is_callable; + /** * Enrich biblio records with authority record data. * @@ -169,6 +171,9 @@ protected function enrichField( } $authRecord = $this->createRecordFromDbRecord($data); + if (!is_callable([$authRecord, 'getAlternativeNames'])) { + return; + } if ($altNames = $authRecord->getAlternativeNames()) { $solrArray[$solrField] = array_merge($solrArray[$solrField] ?? [], $altNames); diff --git a/tests/RecordManagerTest/Base/Enrichment/AuthEnrichmentTest.php b/tests/RecordManagerTest/Base/Enrichment/AuthEnrichmentTest.php index fe1ebc2a..25f0dcfc 100644 --- a/tests/RecordManagerTest/Base/Enrichment/AuthEnrichmentTest.php +++ b/tests/RecordManagerTest/Base/Enrichment/AuthEnrichmentTest.php @@ -85,6 +85,15 @@ public static function getAuthEnrichmentData(): Generator 'author2' => ['Secondary Author With Missing Authority'], ], ]; + yield 'no get alternative names method' => [ + 'fixture' => 'marc_auth_2.xml', + 'authorityRecords' => [ + '(FIN11)authority_002' => 'forward_authority_1.xml', + ], + 'config' => [], + 'authorIds' => ['(FIN11)authority_002'], + 'expected' => [], + ]; } /** @@ -117,7 +126,9 @@ public function testAuthEnrichment( $enricher = $this->getAuthEnricher($authorityRecords, $config); $enricher->enrich('test', $record, $fields); - + if (!$expected) { + $this->assertArrayNotHasKey('author_variant', $fields, 'author_variant field should not be present.'); + } foreach ($expected as $key => $value) { $this->assertEquals($value, $fields[$key] ?? null, "Field '$key' did not match expected value."); } @@ -147,17 +158,30 @@ protected function getAuthEnricher(array $authorityRecords, array $config = []): // Mock authority database records $authorityDbRecords = []; foreach ($authorityRecords as $id => $filename) { - $authorityRecord = $this->createMarcRecord( - \RecordManager\Base\Record\MarcAuthority::class, - $filename, - [] - ); + $authorityRecord = null; + $format = ''; + if (str_contains($filename, 'forward_authority')) { + $authorityRecord = $this->createRecord( + \RecordManager\Base\Record\ForwardAuthority::class, + $filename, + [] + ); + $format = 'forwardAuthority'; + } else { + $authorityRecord = $this->createMarcRecord( + \RecordManager\Base\Record\MarcAuthority::class, + $filename, + [] + ); + $format = 'marc'; + } + $authorityDbRecords[$id] = [ '_id' => $id, 'source_id' => 'test', 'oai_id' => $id, 'deleted' => false, - 'format' => 'marc', + 'format' => $format, 'original_data' => $authorityRecord->serialize(), 'normalized_data' => $authorityRecord->serialize(), ]; @@ -181,11 +205,17 @@ protected function getAuthEnricher(array $authorityRecords, array $config = []): if ($format === 'marc') { return $this->createMarcRecord( \RecordManager\Base\Record\MarcAuthority::class, - 'marc_authority_1.xml', // Dummy, will be replaced + 'marc_authority_1.xml', + [] + ); + } elseif ($format === 'forwardAuthority') { + return $this->createRecord( + \RecordManager\Base\Record\ForwardAuthority::class, + 'forward_authority_1.xml', [] ); } - return null; + throw new \Exception("Unknown format requested in test: $format"); }); $enricher = $this->getMockBuilder(AuthEnrichment::class) diff --git a/tests/fixtures/Base/record/forward_authority_1.xml b/tests/fixtures/Base/record/forward_authority_1.xml new file mode 100644 index 00000000..b7eb3d79 --- /dev/null +++ b/tests/fixtures/Base/record/forward_authority_1.xml @@ -0,0 +1,1174 @@ + + + + + 01 + elonet_henkilo + Kangaroo_0001 + + + Kookaburra_0026 + + + Uusitalo: Jussien viisi vuosikymmentä. SKF 10. HS 6.12.2002. Emu_0027 + + + 04 + Cassowary_0019 + FairyPenguin_0058, SugarGlider_0025 + Quokka_0020 + Koala_0002 + + + 00 + Goanna_0007 + FairyPenguin_0058, Quokka_0020 + + Jussi-palkinnot 1951 parhaasta ohjauksesta sekä käsikirjoituksesta (yhdessä FrilledLizard_0028 kanssa) elokuvasta Radio tekee murron. +Jussi-palkinto 1954 parhaasta ohjauksesta elokuvassa Sininen viikko. +Jussi-palkinto 1955 parhaasta ohjauksesta elokuvissa Isän vanha ja uusi sekä Hilman päivät. +Jussi-palkinto 1957 parhaasta ohjauksesta elokuvassa Elokuu. +Jussi-palkinto 1959 parhaasta käsikirjoituksesta elokuvassa Punainen viiva. +Jussi-palkinto 1962 parhaasta käsikirjoituksesta (yhdessä Wombat_0014 kanssa) elokuvassa Kaasua, komisario Palmu!. +Ylimääräinen valtionpalkinto 1987 (50 000 mk). +BlueTongueSkink_0029 -mitali 1995. +SeaDragon_0010än elokuvajuhlilla 2003 merkittävästä työstä elokuvakulttuurin puolesta (1500e, rahoittajana Canal+). +Elokuvataiteen valtionpalkinto 2008. +Betoni-Jussi 2011 (perustelu: hieno ja merkittävä ura). + + Dingo_0018 + + 01 + elonet_kokoonpano + Wombat_0003 + + + + 51 + 01.01.1900 + Keuruu + + + 52 + 01.01.1900 + Vantaa + + + Suomi + + + + Wallaby_0004 + + Cockatoo_0030 + + + <TitleText>Emu_0001.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvakoko="Platypus_0005">1</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Emu_0001.jpg + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + Wallaby_0004 + + + + Echidna_0006 + + Lyrebird_0031 + + + <TitleText>FrilledLizard_0002.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvakoko="Dingo_0007">2</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + FrilledLizard_0002.jpg + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + Echidna_0006 + + + + Cassowary_0008 + + FairyPenguin_0032 + + + <TitleText>BlueTongueSkink_0003.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvakoko="Quokka_0009">3</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + BlueTongueSkink_0003.jpg + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + Cassowary_0008 + + + + 61357 + + Goanna_0033 + + + <TitleText>Cockatoo_0004.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Lyrebird_0005 ja kirjailija Iki-Echidna_0017 kotona BlueTongueSkink_0003." kuva-kuvakoko="Bilby_0010">14</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Cockatoo_0004.jpg + + A99 + Numbat_0011 + + 01 + elonet_elokuva + Numbat_0011 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Bandicoot_0012 + + 01 + elonet_henkilo + Bandicoot_0012 + + + + DESCRIPTION + + + 61357 + + + + 61358 + + TreeKangaroo_0034 + + + <TitleText>Lyrebird_0005.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Talvikuvausta "Korpiloukon pihalla" Cockatoo_0004ä. Vas. valoheittimien välissä ohjaaja Cassowary_0019, piharakennukseen menossa Emu_0001 roolissa." kuva-kuvakoko="TasmanianDevil_0013">20</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Lyrebird_0005.jpg + + A99 + Numbat_0011 + + 01 + elonet_elokuva + Numbat_0011 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + SugarGlider_0014 + + 01 + elonet_henkilo + SugarGlider_0014 + + + + DESCRIPTION + + + 61358 + + + + 72517 + + RockWallaby_0035 + + + <TitleText>FairyPenguin_0006.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Työkuva, keskellä Cassowary_0019 antaa ohjeita." kuva-kuvakoko="Kookaburra_0015">48</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + FairyPenguin_0006.jpg + + A99 + Emu_0016 + + 01 + elonet_elokuva + Emu_0016 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + 72517 + + + + 72518 + + SeaDragon_0036 + + + <TitleText>Goanna_0007.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Lyrebird_0005 ja käsikirjoittaja Wallaby_0015." kuva-kuvakoko="FrilledLizard_0017">49</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Goanna_0007.jpg + + A99 + Emu_0016 + + 01 + elonet_elokuva + Emu_0016 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + BlueTongueSkink_0018 + + 01 + elonet_henkilo + BlueTongueSkink_0018 + + + + DESCRIPTION + + + 72518 + + + + Cockatoo_0019 + + LeatherbackTurtle_0037 + + + <TitleText>TreeKangaroo_0008.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Lyrebird_0005, valtiovarainministeri Väinö Tanneria esittävä Koala_0013 ja presidentti Bandicoot_0023ä esittävä LeatherbackTurtle_0011." kuva-kuvakoko="Lyrebird_0020">52</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + TreeKangaroo_0008.jpg + + A99 + FairyPenguin_0021 + + 01 + elonet_elokuva + FairyPenguin_0021 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Goanna_0022 + + 01 + elonet_henkilo + Goanna_0022 + + + + A99 + TreeKangaroo_0023 + + 01 + elonet_henkilo + TreeKangaroo_0023 + + + + DESCRIPTION + + + Cockatoo_0019 + + + + RockWallaby_0024 + + Kangaroo_0038 + + + <TitleText>RockWallaby_0009.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="RockWallaby_0009 ja ohjaaja Cassowary_0019, keskellä TasmanianDevil_0024." kuva-kuvakoko="SeaDragon_0025">54</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + RockWallaby_0009.jpg + + A99 + LeatherbackTurtle_0026 + + 01 + elonet_elokuva + LeatherbackTurtle_0026 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Kangaroo_0027 + + 01 + elonet_henkilo + Kangaroo_0027 + + + + A99 + Koala_0028 + + 01 + elonet_henkilo + Koala_0028 + + + + DESCRIPTION + + + RockWallaby_0024 + + + + 74914 + + Koala_0039 + + + <TitleText>SeaDragon_0010.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="ohjaus; käsikirjoitus Cassowary_0019, kuva Kangaroo_0012" kuva-kuvakoko="Wombat_0029">59</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + SeaDragon_0010.jpg + + A99 + Wallaby_0030 + + 01 + elonet_elokuva + Wallaby_0030 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Platypus_0031 + + 01 + elonet_henkilo + Platypus_0031 + + + + DESCRIPTION + + + 74914 + + + + 74917 + + Wombat_0040 + + + <TitleText>LeatherbackTurtle_0011.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="ohjaus; käsikirjoitus Cassowary_0019, apulaisohjaaja Platypus_0016, kuva Kangaroo_0012" kuva-kuvakoko="Echidna_0032">62</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + LeatherbackTurtle_0011.jpg + + A99 + Wallaby_0030 + + 01 + elonet_elokuva + Wallaby_0030 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Platypus_0031 + + 01 + elonet_henkilo + Platypus_0031 + + + + A99 + Dingo_0033 + + 01 + elonet_henkilo + Dingo_0033 + + + + DESCRIPTION + + + 74917 + + + + 74919 + + Wallaby_0041 + + + <TitleText>Kangaroo_0012.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="ohjaus; käsikirjoitus Cassowary_0019, apulaisohjaaja Platypus_0016, kuva Kangaroo_0012" kuva-kuvakoko="Cassowary_0034">64</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Kangaroo_0012.jpg + + A99 + Wallaby_0030 + + 01 + elonet_elokuva + Wallaby_0030 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Dingo_0033 + + 01 + elonet_henkilo + Dingo_0033 + + + + A99 + Platypus_0031 + + 01 + elonet_henkilo + Platypus_0031 + + + + DESCRIPTION + + + 74919 + + + + Quokka_0035 + + Platypus_0042 + + + <TitleText>Koala_0013.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Lyrebird_0005 sekä näyttelijät lukuharjoituksessa." kuva-kuvakoko="Bilby_0036">69</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Koala_0013.jpg + + A99 + Numbat_0037 + + 01 + elonet_elokuva + Numbat_0037 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + Quokka_0035 + + + + Bandicoot_0038 + + Echidna_0043 + + + <TitleText>Wombat_0014.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Numbat_0022 ja TreeKangaroo_0008ärven kirkolla." kuva-kuvakoko="TasmanianDevil_0039">70</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Wombat_0014.jpg + + A99 + Numbat_0037 + + 01 + elonet_elokuva + Numbat_0037 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + SugarGlider_0040 + + 01 + elonet_henkilo + SugarGlider_0040 + + + + DESCRIPTION + + + Bandicoot_0038 + + + + Kookaburra_0041 + + Dingo_0044 + + + <TitleText>Wallaby_0015.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="FairyPenguin_0006, kuvaus Bilby_0021" kuva-kuvakoko="Emu_0042">83</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Wallaby_0015.jpg + + A99 + FrilledLizard_0043 + + 01 + elonet_elokuva + FrilledLizard_0043 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Kangaroo_0027 + + 01 + elonet_henkilo + Kangaroo_0027 + + + + DESCRIPTION + + + Kookaburra_0041 + + + + BlueTongueSkink_0044 + + Cassowary_0045 + + + <TitleText>Platypus_0016.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Lyrebird_0005" kuva-kuvakoko="Cockatoo_0045">85</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Platypus_0016.jpg + + A99 + Lyrebird_0046 + + 01 + elonet_elokuva + Lyrebird_0046 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + BlueTongueSkink_0044 + + + + 31064 + + Quokka_0046 + + + <TitleText>Echidna_0017.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Lyrebird_0005 ”Mietteissä”-luomus." kuva-kuvakoko="FairyPenguin_0047">110</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Echidna_0017.jpg + + A99 + Goanna_0048 + + 01 + elonet_elokuva + Goanna_0048 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + 31064 + + + + TreeKangaroo_0049 + + Bilby_0047 + + + <TitleText>Dingo_0018.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="FrilledLizard_0002 ”Mietteissä”-patsaalla Nurmijärvellä." kuva-kuvakoko="RockWallaby_0050">111</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Dingo_0018.jpg + + A99 + Goanna_0048 + + 01 + elonet_elokuva + Goanna_0048 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + TreeKangaroo_0049 + + + + 66506 + + Numbat_0048 + + + <TitleText>Cassowary_0019.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Edessä Cassowary_0019, kameran takana kuvaaja Bilby_0021." kuva-kuvakoko="SeaDragon_0051">112</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Cassowary_0019.jpg + + A99 + LeatherbackTurtle_0052 + + 01 + elonet_elokuva + LeatherbackTurtle_0052 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Kangaroo_0027 + + 01 + elonet_henkilo + Kangaroo_0027 + + + + DESCRIPTION + + + 66506 + + + + Kangaroo_0053 + + Bandicoot_0049 + + + <TitleText>Quokka_0020.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Lyrebird_0005 paistohommissa." kuva-kuvakoko="Koala_0054">117</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Quokka_0020.jpg + + A99 + LeatherbackTurtle_0052 + + 01 + elonet_elokuva + LeatherbackTurtle_0052 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + Kangaroo_0053 + + + + Wombat_0055 + + TasmanianDevil_0050 + + + <TitleText>Bilby_0021.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Cassowary_0019 ohjaamassa." kuva-kuvakoko="Wallaby_0056">155</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Bilby_0021.jpg + + A99 + Platypus_0057 + + 01 + elonet_elokuva + Platypus_0057 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + Wombat_0055 + + + + Echidna_0058 + + SugarGlider_0051 + + + <TitleText>Numbat_0022.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Cassowary_0019 ohjaamassa, oikealla kuvaaja Kangaroo_0012." kuva-kuvakoko="Dingo_0059">156</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Numbat_0022.jpg + + A99 + Platypus_0057 + + 01 + elonet_elokuva + Platypus_0057 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Platypus_0031 + + 01 + elonet_henkilo + Platypus_0031 + + + + DESCRIPTION + + + Echidna_0058 + + + + Cassowary_0060 + + Kookaburra_0052 + + + <TitleText>Bandicoot_0023.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Cassowary_0019" kuva-kuvakoko="Quokka_0061">158</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Bandicoot_0023.jpg + + A99 + Platypus_0057 + + 01 + elonet_elokuva + Platypus_0057 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + Cassowary_0060 + + + + 71563 + + Emu_0053 + + + <TitleText>TasmanianDevil_0024.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Cassowary_0019, Kangaroo_0012" kuva-kuvakoko="Bilby_0062">160</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + TasmanianDevil_0024.jpg + + A99 + Platypus_0057 + + 01 + elonet_elokuva + Platypus_0057 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + A99 + Platypus_0031 + + 01 + elonet_henkilo + Platypus_0031 + + + + DESCRIPTION + + + 71563 + + + + Numbat_0063 + + FrilledLizard_0054 + + + <TitleText>SugarGlider_0025.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Lyrebird_0005" kuva-kuvakoko="Bandicoot_0064">177</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + SugarGlider_0025.jpg + + A99 + TasmanianDevil_0065 + + 01 + elonet_elokuva + TasmanianDevil_0065 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + Numbat_0063 + + + + SugarGlider_0066 + + BlueTongueSkink_0055 + + + <TitleText>Kookaburra_0026.jpg</TitleText> + <PartDesignation> + <Value kuva-kuvatyyppi="V" kuva-kuvateksti="Lyrebird_0005" kuva-kuvakoko="Kookaburra_0067">178</Value> + </PartDesignation> + <TitleRelationship>unspecified</TitleRelationship> + + Kookaburra_0026.jpg + + A99 + TasmanianDevil_0065 + + 01 + elonet_elokuva + TasmanianDevil_0065 + + + + A99 + Kangaroo_0001 + + 01 + elonet_henkilo + Kangaroo_0001 + + + + DESCRIPTION + + + SugarGlider_0066 + + + diff --git a/tests/fixtures/Base/record/marc_auth_2.xml b/tests/fixtures/Base/record/marc_auth_2.xml new file mode 100644 index 00000000..6a163b35 --- /dev/null +++ b/tests/fixtures/Base/record/marc_auth_2.xml @@ -0,0 +1,17 @@ + + + 00000nam a2200000 i 4500 + marc_auth_test_1 + 20251215000000.0 + 251215s2025 fi 000 0 eng d + + (FIN11)authority_001 + + + Test Book Title + + + (FIN11)authority_001 + + +