mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-05-19 13:49:17 +02:00
They can be close()d explicitly with close-file-descriptor, and will close() on gc, but only explicitly closing the last port on them will close the fileno. Notably needed for network sockets where we open separate input and output ports on the same socket.
20 lines
706 B
Scheme
20 lines
706 B
Scheme
|
|
(import (scheme base) (chibi crypto sha2) (chibi test))
|
|
|
|
(test-begin "sha2")
|
|
|
|
(test "d14a028c2a3a2bc9476102bb288234c415a2b01f828ea62ac5b3e42f"
|
|
(sha-224 ""))
|
|
(test "23097d223405d8228642a477bda255b32aadbce4bda0b3f7e36c9da7"
|
|
(sha-224 "abc"))
|
|
(test "730e109bd7a8a32b1cb9d9a09aa2325d2430587ddbc0c38bad911525"
|
|
(sha-224 "The quick brown fox jumps over the lazy dog"))
|
|
|
|
(test "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
|
|
(sha-256 ""))
|
|
(test "ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad"
|
|
(sha-256 "abc"))
|
|
(test "d7a8fbb307d7809469ca9abcb0082e4f8d5651e46d3cdb762d02d0bf37c9e592"
|
|
(sha-256 "The quick brown fox jumps over the lazy dog"))
|
|
|
|
(test-end)
|