~ruther/guix-local

ref: c8369caccef256f9e7bfa02ac2cc7fcbd72db04f guix-local/tests/utils.scm -rw-r--r-- 2.9 KiB
c8369cac — Ludovic Courtès 13 years ago
Add `base32-string->bytevector' and `nix-base32-string->bytevector'.

* guix/utils.scm (bytevector-quintet-set!,
  bytevector-quintet-set-right!, base32-string-unfold,
  base32-string-unfold-right, make-base32-string->bytevector,
  base32-string->bytevector, nix-base32-string->bytevector): New
  procedures.

* tests/utils.scm ("base32-string->bytevector",
  "nix-base32-string->bytevector"): New tests.
f9c7080a — Ludovic Courtès 13 years ago
Fix `bytevector->nix-base32-string'.

* guix/utils.scm (bytevector-quintet-ref-right,
  bytevector-quintet-fold): New procedures.
  (bytevector-quintet-fold-right): Add `quintet-fold' parameter; use it
  instead of `bytevector-quintet-fold'.
  (bytevector->base32-string): Pass BYTEVECTOR-QUINTET-FOLD as the
  first parameter.
  (bytevector->nix-base32-string): Pass BYTEVECTOR-QUINTET-FOLD-RIGHT as
  the first parameter.

* tests/utils.scm ("sha256 & bytevector->nix-base32-string"): New test.
e3deeebb — Ludovic Courtès 13 years ago
Add (guix utils), with `bytevector->base32-string'.

* guix/utils.scm, tests/utils.scm: New files.