[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnunet-scheme] 01/02: tests/util: Detect if Guile's connection procedur
From: |
gnunet |
Subject: |
[gnunet-scheme] 01/02: tests/util: Detect if Guile's connection procedure is passed. |
Date: |
Wed, 29 Jun 2022 23:31:48 +0200 |
This is an automated email from the git hooks/post-receive script.
maxime-devos pushed a commit to branch master
in repository gnunet-scheme.
commit 333ca8801ae2f44b7b3b379b6225d521910f1000
Author: Maxime Devos <maximedevos@telenet.be>
AuthorDate: Wed Jun 29 17:11:54 2022 +0000
tests/util: Detect if Guile's connection procedure is passed.
Helps with debugging.
* tests/utils.scm (garbage-collectable): Check that the passed
argument 'connect' isn't the 'connect' for connecting sockets, and if
it is, raise an error.
---
tests/utils.scm | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/tests/utils.scm b/tests/utils.scm
index 47875a0..fb41ef3 100644
--- a/tests/utils.scm
+++ b/tests/utils.scm
@@ -234,6 +234,11 @@ callbacks were not called. Also verify that all spawned
fibers exit."
the service daemon is down. Verify that the @var{connected} and
@var{disconnected} callbacks were not called. Also verify that all spawned
fiber exit and the fibers do not keep a reference to the service object."
+ (when (eq? connect (@ (guile) connect))
+ ;; This has happened in the past. Let's make the test failure more
+ ;; more informative, to avoid having to spend time on investigating
+ ;; this in the future.
+ (error "you passed Guile's connect procedure, not connect procedure for
connecting to the GNUnet service!"))
(define (test)
(call-with-spawner/wait
(lambda (spawn)
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.