aboutsummaryrefslogtreecommitdiff
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2014 Nikita Karetnikov <nikita@karetnikov.org>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.

(define-module (test-base64)
  #:use-module (guix base64)
  #:use-module (rnrs bytevectors)
  #:use-module (srfi srfi-64))

(define (string->base64 str)
  (base64-encode (string->utf8 str)))

;;; Test vectors from <https://tools.ietf.org/rfc/rfc4648.txt>.

(test-begin "base64")

(test-equal "empty string"
  (string->base64 "")
  "")

(test-equal "f"
  (string->base64 "f")
  "Zg==")

(test-equal "fo"
  (string->base64 "fo")
  "Zm8=")

(test-equal "foo"
  (string->base64 "foo")
  "Zm9v")

(test-equal "foob"
  (string->base64 "foob")
  "Zm9vYg==")

(test-equal "fooba"
  (string->base64 "fooba")
  "Zm9vYmE=")

(test-equal "foobar"
  (string->base64 "foobar")
  "Zm9vYmFy")

(test-end "base64")
018-08-17 05:19:05 +0200'>2018-08-17gnu: lxc: Update to 3.0.2....* gnu/packages/virtualization.scm (lxc): Update to 3.0.2. [source]: Remove patch. * gnu/packages/patches/lxc-CVE-2018-6556.patch: Delete file. * gnu/local.mk (dist_patch_DATA): Remove it. Tobias Geerinckx-Rice 2018-08-16gnu: qemu: Update to 3.0.0 [mitigate CVE-2018-3639]....* gnu/packages/virtualization.scm (qemu): Update to 3.0.0. [source]: Remove patch. * gnu/packages/patches/qemu-CVE-2018-11806.patch: Delete file. * gnu/local.mk (dist_patch_DATA): Remove it. Tobias Geerinckx-Rice 2018-08-09gnu: qemu: Update to 2.12.1....* gnu/packages/virtualization.scm (qemu): Update to 2.12.1. Marius Bakke 2018-08-08gnu: lxc: Fix CVE-2018-6556....* gnu/packages/patches/lxc-CVE-2018-6556.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/virtualization.scm (lxc)[source]: Use it. Leo Famulari 2018-07-29gnu: Add python-vagrant....* gnu/packages/virtualization.scm (python-vagrant): New variable. Efraim Flashner 2018-07-29gnu: virtualization.scm: Use license prefix....* gnu/packages/virtualization.scm: Replace all 'license' values with a 'license:' prefix. Efraim Flashner 2018-06-22gnu: qemu: Return #t from phases....* gnu/packages/virtualization.scm (qemu)[arguments]: Substitute INVOKE for SYSTEM*. Tobias Geerinckx-Rice 2018-06-22gnu: lxc: Return #t from phases....* gnu/packages/virtualization.scm (lxc)[arguments]: Substitute INVOKE for SYSTEM*. Tobias Geerinckx-Rice 2018-06-22gnu: lookingglass: Update to a11....* gnu/packages/virtualization.scm (lookingglass): Update to a11. [native-inputs]: Add 'libconfig', 'nettle'. [arguments]: Add 'CC=gcc' make-flag. Rutger Helling 2018-06-19gnu: QEMU: Fix CVE-2018-11806....* gnu/packages/patches/qemu-CVE-2018-11806.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/virtualization.scm (qemu)[source]: Use it. Leo Famulari 2018-06-12gnu: Add skopeo....* gnu/packages/virtualization.scm (skopeo): New variable. 宋文武 2018-06-12gnu: Add umoci....* gnu/packages/virtualization.scm (umoci): New variable. 宋文武 2018-06-09gnu: lxc: Update to 3.0.1....* gnu/packages/virtualization.scm (lxc): Update to 3.0.1. 宋文武 2018-05-06Merge branch 'master' into core-updatesMarius Bakke 2018-05-02gnu: libvirt: Update to 4.3.0....* gnu/packages/virtualization.scm (libvirt): Update to 4.3.0. Tobias Geerinckx-Rice 2018-04-30Merge branch 'master' into core-updatesMark H Weaver 2018-04-28gnu: virt-manager: Update to 1.5.1....* gnu/packages/virtualization.scm (virt-manager): Update to 1.5.1. Roel Janssen 2018-04-26gnu: qemu: Enable GTK3 frontend....* gnu/packages/virtualization.scm (qemu)[native-inputs]: Add "gettext" to native-inputs. [inputs]: Add "gtk+" to inputs. * gnu/packages/virtualization.scm (qemu-minimal)[native-inputs]: Remove "gettext" from inherited inputs. [inputs]: Remove "gtk+" from inherited inputs. Rutger Helling 2018-04-26gnu: qemu: Build with Python 3 and SDL2 support....* gnu/packages/bootloaders.scm (qemu-minimal-2.10): Remove variable. * gnu/packages/virtualization.scm (qemu)[inputs]: Use sdl2 instead of sdl. [native-inputs]: Use python-wrapper instead of python@2. * gnu/packages/virtualization.scm (qemu-minimal)[inputs]: Remove sdl2 instead of sdl from inherited packages. * gnu/packages/virtualization.scm (qemu-minimal-2.10): Add variable. [native-inputs]: Remove python-wrapper from inherited packages and use python@2 instead. * gnu/packages/debug.scm (american-fuzzy-lop): Inherit from moved hidden-package qemu-minimal-2.10. Rutger Helling 2018-04-26gnu: runc: Update comment about status of tests....* gnu/packages/virtualization.scm (runc)[arguments]: Update comment. 宋文武 2018-04-24gnu: qemu: Update to 2.12.0....* gnu/packages/patches/qemu-CVE-2018-7550.patch: Delete file. * gnu/local.mk (dist_patch_DATA): Remove it. * gnu/packages/virtualization.scm (qemu): Update to 2.12.0. [source](patches): Remove. Marius Bakke 2018-04-23gnu: Add runc....* gnu/packages/virtualization.scm (runc): New variable. 宋文武 2018-04-21Merge branch 'master' into core-updatesMark H Weaver 2018-04-18gnu: qemu: Fix CVE-2018-7550....* gnu/packages/patches/qemu-CVE-2018-7550.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/virtualization.scm (qemu)[source]: Use it. Leo Famulari 2018-04-10gnu: qemu: Fix build with glibc-2.27....* gnu/packages/patches/qemu-glibc-2.27.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/virtualization.scm (qemu)[source]: Add patch. [native-inputs]: Add flex and bison. * gnu/packages/bootloaders.scm (qemu-minimal-2.10)[source]: Add patch. Mark H Weaver 2018-04-03gnu: python-libvirt: Update to 4.1.0....* gnu/packages/virtualization.scm (python-libvirt): Update to 4.1.0. Tobias Geerinckx-Rice 2018-04-03gnu: libvirt: Update to 4.2.0....2018-01-09gnu: fe2018-03-21gnu: libosinfo: Update usb.ids....This follows up commit 0def9120882f90372fd6bb2e80e8330d67745610, which tried to use the CVS ID as the SVN revision, which unfortunately doesn't work. * gnu/packages/virtualization.scm (libosinfo)[native-inputs]: Update revision and hash for ‘usb.ids’. Tobias Geerinckx-Rice 2018-03-21gnu: libosinfo: Fix URL for usb.ids....Fixes <http://bugs.gnu.org/30890>. * gnu/packages/virtualization.scm (libosinfo)[native-inputs]: Fix URL of "usb.ids". Danny Milosavljevic 2018-03-17gnu: Fix common unquote typos....It's easy to mistype ‘("foo" foo)’ as ‘("foo", foo)’ (which also works). Fix such typos for the proper edification of our young. * gnu/packages/android.scm: Move unquotes to their operands. * gnu/packages/bootloaders.scm: Likewise. * gnu/packages/build-tools.scm: Likewise. * gnu/packages/chemistry.scm: Likewise. * gnu/packages/compression.scm: Likewise. * gnu/packages/connman.scm: Likewise. * gnu/packages/django.scm: Likewise. * gnu/packages/emulators.scm: Likewise. * gnu/packages/engineering.scm: Likewise. * gnu/packages/file-systems.scm: Likewise. * gnu/packages/freedesktop.scm: Likewise. * gnu/packages/games.scm: Likewise. * gnu/packages/gimp.scm: Likewise. * gnu/packages/gl.scm: Likewise. * gnu/packages/gnome.scm: Likewise. * gnu/packages/graphics.scm: Likewise. * gnu/packages/haskell.scm: Likewise. * gnu/packages/irc.scm: Likewise. * gnu/packages/julia.scm: Likewise. * gnu/packages/kde-frameworks.scm: Likewise. * gnu/packages/linux.scm: Likewise. * gnu/packages/lua.scm: Likewise. * gnu/packages/mail.scm: Likewise. * gnu/packages/make-bootstrap.scm: Likewise. * gnu/packages/messaging.scm: Likewise. * gnu/packages/music.scm: Likewise. * gnu/packages/networking.scm: Likewise. * gnu/packages/ocaml.scm: Likewise. * gnu/packages/perl.scm: Likewise. * gnu/packages/python.scm: Likewise. * gnu/packages/python-web.scm: Likewise. * gnu/packages/qt.scm: Likewise. * gnu/packages/ratpoison.scm: Likewise. * gnu/packages/sdl.scm: Likewise. * gnu/packages/sml.scm: Likewise. * gnu/packages/terminals.scm: Likewise. * gnu/packages/text-editors.scm: Likewise. * gnu/packages/video.scm: Likewise. * gnu/packages/virtualization.scm: Likewise. * gnu/packages/vulkan.scm: Likewise. * gnu/packages/wget.scm: Likewise. * gnu/packages/wine.scm: Likewise. * gnu/packages/wm.scm: Likewise. * gnu/packages/xdisorg.scm: Likewise. * gnu/packages/xml.scm: Likewise. * gnu/packages/xorg.scm: Likewise. Tobias Geerinckx-Rice 2018-03-12gnu: criu: Update to 3.7....* gnu/packages/virtualization.scm (criu): Update to 3.7. Tobias Geerinckx-Rice 2018-02-20gnu: qemu: Update to 2.11.1....* gnu/packages/patches/qemu-CVE-2017-15038.patch, gnu/packages/patches/qemu-CVE-2017-15289.patch: Delete files. * gnu/local.mk (dist_patch_DATA): Remove them. * gnu/packages/virtualization.scm (qemu): Update to 2.11.1 [source](patches): Remove. Marius Bakke 2018-02-10gnu: qemu: Add pulseaudio support....* gnu/packages/virtualization.scm (qemu)[arguments]: Add --audio-drv-list flag. [inputs]: Add pulseaudio. (qemu-minimal)[inputs]: Remove pulseaudio. Oleg Pykhalov