~ chicken-core (chicken-5) d856a53aa194922b73f480f0e943c38268ef93f1
commit d856a53aa194922b73f480f0e943c38268ef93f1
Author: felix <felix@call-with-current-continuation.org>
AuthorDate: Mon Aug 27 21:49:54 2012 +0200
Commit: Mario Domenech Goulart <mario.goulart@gmail.com>
CommitDate: Mon Aug 27 17:51:54 2012 -0300
in signal-tests terminate child process by signal instead of tcp-message because the test will never finish if the tcp-listen operation fails, for example, when the port is already in use
Fixes #907.
Signed-off-by: Mario Domenech Goulart <mario.goulart@gmail.com>
diff --git a/tests/signal-tests.scm b/tests/signal-tests.scm
index 6f004401..b9e5f415 100644
--- a/tests/signal-tests.scm
+++ b/tests/signal-tests.scm
@@ -7,10 +7,7 @@
(exit))
-;;XXX not tested yet
-
-
-(use posix srfi-18 extras tcp)
+(use posix srfi-18 extras)
(define received1 0)
@@ -36,14 +33,6 @@
(define (child)
(print "child started")
- (thread-start!
- (lambda ()
- (let-values (((i o) (tcp-accept (tcp-listen 9999))))
- (tick #\!)
- (assert (string=? "ok." (read-line i)))
- (print "client connected.")
- (close-input-port i)
- (close-output-port o))))
(thread-start!
(lambda ()
(do () (#f)
@@ -76,10 +65,5 @@
(set! sent2 (add1 sent2))
(process-signal pid signal/usr2)))))
(printf "~%signals sent: ~a USR1, ~a USR2~%" sent1 sent2)
- (print "connecting ...")
- (let-values (((i o) (tcp-connect "localhost" 9999)))
- (display "ok.\n" o)
- (close-input-port i)
- (close-output-port o)
- (sleep 1))
+ (print "terminating child process ...")
(process-signal pid))
Trap