(use udp test) (define s (udp-open-socket)) (udp-bind! s "localhost" 1234) (udp-connect! s "localhost" 1234) (udp-send s "hello\n") (test-group "udp send/receive test" (test "6 bytes from 127.0.0.1:1234: hello\n" (receive (n data from-host from-port) (udp-recvfrom s 64) (sprintf "~A bytes from ~A:~A: ~A" n from-host from-port data)) )) (udp-close-socket s) (test-exit)