Handbook
Glossary
mock-smtp-server ( promise -- )
Vocabulary
smtp
.
server
Inputs
promise
an
object
Outputs
None
Definition
USING:
accessors
calendar
concurrency.promises
destructors
io
io.encodings.ascii
io.sockets
io.sockets.secure.debug
io.streams.duplex
io.timeouts
kernel
namespaces
threads
;
IN:
smtp.server
::
mock-smtp-server
( promise -- )
[
[
"127.0.0.1"
0
<inet4>
ascii
<server>
[
dup
addr>>
port>>
promise
fulfill
accept
drop
[
1
minutes
timeouts
"220 hello\r\n"
write
flush
process
[
flush
]
with-global
]
with-stream
]
with-disposal
]
with-test-context
]
in-thread
;