You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jena.apache.org by an...@apache.org on 2025/03/07 16:39:36 UTC
(jena) branch main updated: GH-3050: Fixed open iterator in test case for custom service executors.
This is an automated email from the ASF dual-hosted git repository.
andy pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/jena.git
The following commit(s) were added to refs/heads/main by this push:
new 4d3d91e0fd GH-3050: Fixed open iterator in test case for custom service executors.
4d3d91e0fd is described below
commit 4d3d91e0fd9ef08c5f0adc79873b5d87be462f16
Author: Claus Stadler <Ra...@googlemail.com>
AuthorDate: Fri Mar 7 16:06:27 2025 +0100
GH-3050: Fixed open iterator in test case for custom service executors.
---
.../java/org/apache/jena/test/service/TestCustomServiceExecutor.java | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/jena-integration-tests/src/test/java/org/apache/jena/test/service/TestCustomServiceExecutor.java b/jena-integration-tests/src/test/java/org/apache/jena/test/service/TestCustomServiceExecutor.java
index c31e267ffb..b02c72f43f 100644
--- a/jena-integration-tests/src/test/java/org/apache/jena/test/service/TestCustomServiceExecutor.java
+++ b/jena-integration-tests/src/test/java/org/apache/jena/test/service/TestCustomServiceExecutor.java
@@ -39,6 +39,7 @@ import org.apache.jena.sparql.core.Var;
import org.apache.jena.sparql.engine.ExecutionContext;
import org.apache.jena.sparql.engine.QueryIterator;
import org.apache.jena.sparql.engine.binding.Binding;
+import org.apache.jena.sparql.engine.iterator.QueryIter;
import org.apache.jena.sparql.exec.QueryExec;
import org.apache.jena.sparql.resultset.ResultSetCompare;
import org.apache.jena.sparql.service.ServiceExec;
@@ -146,7 +147,7 @@ public class TestCustomServiceExecutor {
return ServiceExec.exec(new OpService(b, opService.getSubOp(), false), input, execCxt);
} else if (node.equals(c)) {
// 4. Match 'c' and return the test table
- return table.iterator(execCxt);
+ return QueryIter.flatMap(input, x -> table.iterator(execCxt), execCxt);
} else {
throw new RuntimeException("Unexpectedly got: " + node);
}