aboutsummaryrefslogtreecommitdiff
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2016-2017, 2024 Ludovic Courtès <ludo@gnu.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-modules)
  #:use-module (guix modules)
  #:use-module ((guix build-system gnu) #:select (%default-gnu-imported-modules))
  #:use-module ((guix utils) #:select (call-with-temporary-directory))
  #:use-module (srfi srfi-1)
  #:use-module (srfi srfi-34)
  #:use-module (srfi srfi-64))

(test-begin "modules")

(test-assert "closure of (guix build gnu-build-system)"
  (lset= equal?
         (live-module-closure '((guix build gnu-build-system)))
         (source-module-closure '((guix build gnu-build-system)))
         %default-gnu-imported-modules
         (source-module-closure %default-gnu-imported-modules)
         (live-module-closure %default-gnu-imported-modules)))

(test-assert "closure of (gnu build install)"
  (lset= equal?
         (live-module-closure '((gnu build install)))
         (source-module-closure '((gnu build install)))))

(test-assert "closure of (gnu build image)"
  (lset= equal?
         (live-module-closure '((gnu build image)))
         (source-module-closure '((gnu build image)))))

(test-equal "&missing-dependency-error"
  '(something that does not exist)
  (call-with-temporary-directory
   (lambda (directory)
     (call-with-output-file (string-append directory "/foobar.scm")
       (lambda (port)
         (write '(define-module (foobar)
                   #:use-module (something that does not exist))
                port)))

     (call-with-output-file (string-append directory "/baz.scm")
       (lambda (port)
         (write '(define-module (baz)
                   #:use-module (foobar))
                port)))

     (guard (c ((missing-dependency-error? c)
                (missing-dependency-module c)))
       (source-module-closure '((baz)) (list directory)
                              #:select? (const #t))))))

(test-equal "file-name->module-name"
  '(guix foo)
  (file-name->module-name "guix/foo.scm"))

(test-equal "file-name->module-name, leading dot"
  '(guix foo)
  (file-name->module-name "./guix/foo.scm"))

(test-end)
?id=86c1f3857cfb9b6fec292ce327b2f57dcc2cd04e'>gnu: fcitx5-configtool: Enable kcm support.Zheng Junjie * gnu/packages/fcitx5.scm (fcitx5-configtool) [arguments]: Remove it. [inputs]: Add qtdeclarative, qtquickcontrols2, ki18n, kpackage, kdeclarative, kiconthemes, kcoreaddons, plasma-framework, kwindowsystem, kirigami, libxkbcommon. Change-Id: I43a43458232a5ad3c1d156c779359e356cbf98b8 Signed-off-by: Christopher Baines <mail@cbaines.net> 2024-01-18gnu: libime: Update to 1.1.5.宋文武 * gnu/packages/fcitx5.scm (libime): Update to 1.1.5. Change-Id: I5dc2b083df7b3b3f4ed93bcbf2e86190d647a497 2024-01-18gnu: fcitx5: Update to 5.1.7.宋文武 * gnu/packages/fcitx5.scm (fcitx5): Update to 5.1.7. Change-Id: Ifd87b6bb21afd2980d95a09177f28048d9a7e182 2024-01-18gnu: fcitx5-rime: Update to 5.1.4.宋文武 * gnu/packages/fcitx5.scm (fcitx5-rime): Update to 5.1.4. Change-Id: If418aff57363ffc2f2469eedbf90606d7ff3aac8 2024-01-18gnu: fcitx5-configtool: Update to 5.1.3.宋文武 * gnu/packages/fcitx5.scm (fcitx5-configtool): Update to 5.1.3. Change-Id: I9b75478fb4b3fe1d690de9f33a0dce02781a05a3 2024-01-18gnu: fcitx5-chinese-addons: Update to 5.1.3.宋文武 * gnu/packages/fcitx5.scm (fcitx5-chinese-addons): Update to 5.1.3. Change-Id: I90c8231e967add94c59c4c912025100b9f4bca57 2024-01-18gnu: fcitx5-anthy: Update to 5.1.3.宋文武 * gnu/packages/fcitx5.scm (fcitx5-anthy): Update to 5.1.3. Change-Id: Ifb45a5e36aeb03f54df449c60ab58ee8f393d534 2024-01-18gnu: fcitx5-qt: Update to 5.1.4.宋文武 * gnu/packages/fcitx5.scm (fcitx5-qt): Update to 5.1.4. Change-Id: Ie2b8a3bb061d4a068602a841dae4b50a37715668 2024-01-18gnu: fcitx5-gtk: Update to 5.1.1.宋文武 * gnu/packages/fcitx5.scm (fcitx5-gtk): Update to 5.1.1. Change-Id: If4d6fcddc1a284aa02519b93fdd89664ec1915d5 2024-01-18gnu: libime: Update to 1.1.4.宋文武 * gnu/packages/fcitx5.scm (libime): Update to 1.1.4. Change-Id: Ibf60683739337e886316ea88d97e899053469ed7 2024-01-18gnu: fcitx5-lua: Update to 5.0.12.宋文武 * gnu/packages/fcitx5.scm (fcitx5-lua): Update to 5.0.12. Change-Id: Ie4b4c3496a59a0a956359a73a780de8a6c2211f7 2024-01-18gnu: fcitx5: Update to 5.1.6.宋文武 * gnu/packages/fcitx5.scm (fcitx5): Update to 5.1.6. [inputs]: Add libuv. Change-Id: I77e722c8ae76272ce76bbb42e5a3a01d81dff433 2024-01-18gnu: xcb-imdkit: Update to 1.0.6.宋文武 * gnu/packages/fcitx5.scm (xcb-imdkit): Update to 1.0.6. Change-Id: If5398cee97d20fed4e1f643fabc8950f007d6786 2023-11-22gnu: fcitx5-rime: Update to 5.1.3.宋文武 * gnu/packages/fcitx5.scm (fcitx5-rime): Update to 5.1.3. Change-Id: Ia7939616d93ec0235b9fd50f2ae2a26d551a650c 2023-11-22gnu: fcitx5-configtool: Update to 5.1.2.宋文武 * gnu/packages/fcitx5.scm (fcitx5-configtool): Update to 5.1.2. Change-Id: I534cb1943c09d5a36f171608fcbb6b09661d2bb4 2023-11-22gnu: fcitx5-chinese-addons: Update to 5.1.2.宋文武 * gnu/packages/fcitx5.scm (fcitx5-chinese-addons): Update to 5.1.2. Change-Id: Icbfa1628c23adfc5c2789480c9803a1b1c257a0f 2023-11-22gnu: fcitx5-qt: Update to 5.1.3.宋文武 * gnu/packages/fcitx5.scm (fcitx5-qt): Update to 5.1.3. Change-Id: Id0b375c7d052f2d2d8a4d10f8415b748823efe14 2023-11-22gnu: fcitx5-anthy: Update to 5.1.2.宋文武 * gnu/packages/fcitx5.scm (fcitx5-anthy): Update to 5.1.2. Change-Id: I0e6e8b3774221fdb91ee91fa2870cdda3d6e9273 2023-11-22gnu: libime: Update to 1.1.3.宋文武 * gnu/packages/fcitx5.scm (libime): Update to 1.1.3. [inputs]: Add zstd:lib. [native-inputs]: Add pkg-config and remove python. Change-Id: Ia3a580c2292b68a8f492b29c37d7219a77271d54 2023-11-22gnu: fcitx5-lua: Update to 5.0.11.宋文武 * gnu/packages/fcitx5.scm (fcitx5-lua): Update to 5.0.11. Change-Id: Iacfd1a197c888cc1a79e31723c57e5ac34a8a7f5 2023-11-22gnu: fcitx5: Update to 5.1.5.宋文武 * gnu/packages/fcitx5.scm (fcitx5): Update to 5.1.5. Change-Id: I6e3ac3c8ad77fd53d431bd1501ae6b44ad49a66a 2023-08-23gnu: fcitx5-rime: Update to 5.1.1.宋文武 * gnu/packages/fcitx5.scm (fcitx5-rime): Update to 5.1.1. 2023-08-23gnu: fcitx5-configtool: Update to 5.1.0.宋文武 * gnu/packages/fcitx5.scm (fcitx5-configtool): Update to 5.1.0. 2023-08-23gnu: fcitx5-chinese-addons: Update to 5.1.0.宋文武 * gnu/packages/fcitx5.scm (fcitx5-chinese-addons): Update to 5.1.0. 2023-08-23gnu: fcitx5-anthy: Update to 5.1.0.宋文武 * gnu/packages/fcitx5.scm (fcitx5-anthy): Update to 5.1.0. 2023-08-23gnu: fcitx5-qt: Update to 5.1.0.宋文武 * gnu/packages/fcitx5.scm (fcitx5-qt): Update to 5.1.0. 2023-08-23gnu: fcitx5-gtk: Update to 5.1.0.宋文武 * gnu/packages/fcitx5.scm (fcitx5-gtk): Update to 5.1.0. 2023-08-23gnu: libime: Update to 1.1.0.宋文武 * gnu/packages/fcitx5.scm (libime): Update to 1.1.0. 2023-08-23gnu: fcitx5: Update to 5.1.0.宋文武 * gnu/packages/fcitx5.scm (fcitx5): Update to 5.1.0. [inputs]: Remove libpthread-stubs, libx11, libxfixes, libxinerama and unicode-cldr-common. [arguments]: Pass "-DUSE_SYSTEMD=OFF" as configure-flags.