From 4583b0a742db47317bf4d141b02672e178c62857 Mon Sep 17 00:00:00 2001 From: Heiko Schaefer Date: Mon, 10 Jul 2023 18:59:06 +0200 Subject: [PATCH] TMP: make backward_propagate public, for tests --- .../src/main/kotlin/org/pgpainless/wot/dijkstra/Query.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/Query.kt b/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/Query.kt index 61d296ef..5d051b25 100644 --- a/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/Query.kt +++ b/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/Query.kt @@ -190,8 +190,10 @@ class Query( * to longer paths. So the returned path(s) may not be optimal in terms of the amount of trust. * To compensate for this, the caller should run the algorithm again on * a residual network. + * + * FIXME: public for unit tests (undo!) */ - private fun backwardPropagate(targetFpr: Fingerprint, targetUserid: String, filter: CertificationFilter): HashMap> { + fun backwardPropagate(targetFpr: Fingerprint, targetUserid: String, filter: CertificationFilter): HashMap> { // Prefer paths where the target User ID is self-signed as long as possible. (But .. Why?) val authPaths = backwardPropagateInternal(targetFpr, targetUserid, true, filter)