diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2022-03-03 02:32:04 +0100 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2022-03-07 22:00:16 +0100 |
commit | 7dea1c7799b7d57f56bad3f81389d8a150220c82 (patch) | |
tree | ae8528e6480123cfde46dba4557ad016c04a5396 /tests/test/crypto.scm | |
parent | Add tests for (crypto) module. (diff) | |
download | calp-7dea1c7799b7d57f56bad3f81389d8a150220c82.tar.gz calp-7dea1c7799b7d57f56bad3f81389d8a150220c82.tar.xz |
Rewrote checksum->string.
Lets take full advantage of guile's format.
Diffstat (limited to 'tests/test/crypto.scm')
-rw-r--r-- | tests/test/crypto.scm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/test/crypto.scm b/tests/test/crypto.scm index 610ac819..71ecfc99 100644 --- a/tests/test/crypto.scm +++ b/tests/test/crypto.scm @@ -7,3 +7,9 @@ (test-equal "sha256 string digest" "185f8db32271fe25f561a6fc938b2e264306ec304eda518007d1764826381969" (checksum->string (sha256 "Hello"))) + +(let ((port (open-output-string))) + (checksum->string (sha256 "Hello") port) + (test-equal "sha256 string digest to port" + "185f8db32271fe25f561a6fc938b2e264306ec304eda518007d1764826381969" + (get-output-string port))) |