1
0
Fork 0

[BipFinderInstanceLevel] change pom to align to the dhp-schema release 2.10.24 and refactoring

This commit is contained in:
Miriam Baglioni 2022-01-12 18:06:26 +01:00
parent 4d517ed9ec
commit a75fb8c47a
2 changed files with 48 additions and 25 deletions

View File

@ -245,26 +245,47 @@ public class ProduceTest {
.get(0) .get(0)
.getValue()); .getValue());
Assertions.assertEquals("10.3390/s18072310", Assertions
tmp.filter(row -> row.getId().equals(doi)).collect() .assertEquals(
.get(0) "10.3390/s18072310",
.getInstance().get(0) tmp
.getPid().get(0) .filter(row -> row.getId().equals(doi))
.getValue().toLowerCase()); .collect()
.get(0)
.getInstance()
.get(0)
.getPid()
.get(0)
.getValue()
.toLowerCase());
Assertions.assertEquals("doi", Assertions
tmp.filter(row -> row.getId().equals(doi)).collect() .assertEquals(
.get(0) "doi",
.getInstance().get(0) tmp
.getPid().get(0) .filter(row -> row.getId().equals(doi))
.getQualifier().getClassid()); .collect()
.get(0)
.getInstance()
.get(0)
.getPid()
.get(0)
.getQualifier()
.getClassid());
Assertions.assertEquals("Digital Object Identifier", Assertions
tmp.filter(row -> row.getId().equals(doi)).collect() .assertEquals(
.get(0) "Digital Object Identifier",
.getInstance().get(0) tmp
.getPid().get(0) .filter(row -> row.getId().equals(doi))
.getQualifier().getClassname()); .collect()
.get(0)
.getInstance()
.get(0)
.getPid()
.get(0)
.getQualifier()
.getClassname());
} }
@ -274,15 +295,17 @@ public class ProduceTest {
JavaRDD<Result> tmp = getResultJavaRDD(); JavaRDD<Result> tmp = getResultJavaRDD();
List<StructuredProperty> mes = tmp List<StructuredProperty> mes = tmp
.filter(row -> row.getInstance() != null && row.getInstance().size() > 0) .filter(row -> row.getInstance() != null && row.getInstance().size() > 0)
.flatMap(row -> row.getInstance().iterator()) .flatMap(row -> row.getInstance().iterator())
.flatMap(i -> i.getPid().iterator()) .flatMap(i -> i.getPid().iterator())
.collect(); .collect();
Assertions.assertEquals(86, mes.size()); Assertions.assertEquals(86, mes.size());
tmp.filter(row -> row.getInstance() != null && row.getInstance().size() > 0) tmp
.foreach(e -> Assertions.assertEquals("sysimport:enrich", e.getDataInfo().getProvenanceaction().getClassid())); .filter(row -> row.getInstance() != null && row.getInstance().size() > 0)
.foreach(
e -> Assertions.assertEquals("sysimport:enrich", e.getDataInfo().getProvenanceaction().getClassid()));
} }

View File

@ -797,7 +797,7 @@
<mockito-core.version>3.3.3</mockito-core.version> <mockito-core.version>3.3.3</mockito-core.version>
<mongodb.driver.version>3.4.2</mongodb.driver.version> <mongodb.driver.version>3.4.2</mongodb.driver.version>
<vtd.version>[2.12,3.0)</vtd.version> <vtd.version>[2.12,3.0)</vtd.version>
<dhp-schemas.version>[2.9.25-SNAPSHOT]</dhp-schemas.version> <dhp-schemas.version>[2.10.24]</dhp-schemas.version>
<dnet-actionmanager-api.version>[4.0.3]</dnet-actionmanager-api.version> <dnet-actionmanager-api.version>[4.0.3]</dnet-actionmanager-api.version>
<dnet-actionmanager-common.version>[6.0.5]</dnet-actionmanager-common.version> <dnet-actionmanager-common.version>[6.0.5]</dnet-actionmanager-common.version>
<dnet-openaire-broker-common.version>[3.1.6]</dnet-openaire-broker-common.version> <dnet-openaire-broker-common.version>[3.1.6]</dnet-openaire-broker-common.version>