From 66d0e0d3f29a95d4b699e82ffa74b4c857397118 Mon Sep 17 00:00:00 2001 From: "miriam.baglioni" Date: Wed, 19 Aug 2020 11:31:50 +0200 Subject: [PATCH] - --- .../dump/graph/DumpOrganizationProjectDatasourceTest.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/dhp-workflows/dhp-graph-mapper/src/test/java/eu/dnetlib/dhp/oa/graph/dump/graph/DumpOrganizationProjectDatasourceTest.java b/dhp-workflows/dhp-graph-mapper/src/test/java/eu/dnetlib/dhp/oa/graph/dump/graph/DumpOrganizationProjectDatasourceTest.java index d855f279d..e6d644998 100644 --- a/dhp-workflows/dhp-graph-mapper/src/test/java/eu/dnetlib/dhp/oa/graph/dump/graph/DumpOrganizationProjectDatasourceTest.java +++ b/dhp-workflows/dhp-graph-mapper/src/test/java/eu/dnetlib/dhp/oa/graph/dump/graph/DumpOrganizationProjectDatasourceTest.java @@ -10,6 +10,7 @@ import org.apache.commons.io.FileUtils; import org.apache.spark.SparkConf; import org.apache.spark.api.java.JavaRDD; import org.apache.spark.api.java.JavaSparkContext; +import org.apache.spark.api.java.function.ForeachFunction; import org.apache.spark.sql.Encoders; import org.apache.spark.sql.SparkSession; import org.junit.jupiter.api.AfterAll; @@ -89,7 +90,7 @@ public class DumpOrganizationProjectDatasourceTest { Assertions.assertEquals(34, verificationDataset.count()); - verificationDataset.foreach(o -> System.out.println(OBJECT_MAPPER.writeValueAsString(o))); + verificationDataset.foreach((ForeachFunction) o -> System.out.println(OBJECT_MAPPER.writeValueAsString(o))); } @@ -115,7 +116,7 @@ public class DumpOrganizationProjectDatasourceTest { Assertions.assertEquals(12, verificationDataset.count()); - verificationDataset.foreach(o -> System.out.println(OBJECT_MAPPER.writeValueAsString(o))); + verificationDataset.foreach((ForeachFunction) o -> System.out.println(OBJECT_MAPPER.writeValueAsString(o))); } @@ -140,7 +141,7 @@ public class DumpOrganizationProjectDatasourceTest { Assertions.assertEquals(5, verificationDataset.count()); - verificationDataset.foreach(o -> System.out.println(OBJECT_MAPPER.writeValueAsString(o))); + verificationDataset.foreach((ForeachFunction) o -> System.out.println(OBJECT_MAPPER.writeValueAsString(o))); } }