summaryrefslogtreecommitdiff
path: root/gnu/tests
diff options
context:
space:
mode:
authorThéo Tyburn <theo.tyburn@posteo.net>2026-06-03 10:56:10 +0200
committerNguyễn Gia Phong <cnx@loang.net>2026-08-31 11:00:19 +0900
commitc62ebcd02c2eb190ab5dc157475ef4a93a1c7581 (patch)
treef178f262874978ac0be45e5499db5cc2d63248fe /gnu/tests
parent30cb1f541eb99b0fbbec1f8f29796151103c5f2b (diff)
doc: Move Commentary above module definition.
Merges: https://codeberg.org/guix/guix/pulls/9052 Reviewed-by: Ludovic Courtès <ludo@gnu.org> Reviewed-by: Maxim Cournoyer <maxim@guixotic.coop> Signed-off-by: Nguyễn Gia Phong <cnx@loang.net>
Diffstat (limited to 'gnu/tests')
-rw-r--r--gnu/tests/image.scm22
-rw-r--r--gnu/tests/install.scm14
-rw-r--r--gnu/tests/linux-modules.scm12
-rw-r--r--gnu/tests/package-management.scm12
-rw-r--r--gnu/tests/reconfigure.scm14
5 files changed, 37 insertions, 37 deletions
diff --git a/gnu/tests/image.scm b/gnu/tests/image.scm
index be6852cae0a..3e7629c3b68 100644
--- a/gnu/tests/image.scm
+++ b/gnu/tests/image.scm
@@ -16,6 +16,17 @@
16;;; You should have received a copy of the GNU General Public License 16;;; You should have received a copy of the GNU General Public License
17;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. 17;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
18 18
19;;; Commentary:
20;;;
21;;; This module provides tests for the image creation process that is
22;;; performed by "genimage" under the hood.
23;;;
24;;; The image partitionment is checked using Guile-Parted. The content of the
25;;; images is out of the scope of this module. Other test modules such as
26;;; (gnu tests installation) make sure that the produced images are viable.
27;;;
28;;; Code:
29
19(define-module (gnu tests image) 30(define-module (gnu tests image)
20 #:use-module (gnu) 31 #:use-module (gnu)
21 #:use-module (gnu image) 32 #:use-module (gnu image)
@@ -30,17 +41,6 @@
30 #:use-module (ice-9 format) 41 #:use-module (ice-9 format)
31 #:export (%test-images)) 42 #:export (%test-images))
32 43
33;;; Commentary:
34;;;
35;;; This module provides tests for the image creation process that is
36;;; performed by "genimage" under the hood.
37;;;
38;;; The image partitionment is checked using Guile-Parted. The content of the
39;;; images is out of the scope of this module. Other test modules such as
40;;; (gnu tests installation) make sure that the produced images are viable.
41;;;
42;;; Code:
43
44;; A dummy initializer creating a simple file in the partition. 44;; A dummy initializer creating a simple file in the partition.
45(define dummy-initializer 45(define dummy-initializer
46 #~(lambda* (root . rest) 46 #~(lambda* (root . rest)
diff --git a/gnu/tests/install.scm b/gnu/tests/install.scm
index 91ab59ce8d2..2c336ce4e94 100644
--- a/gnu/tests/install.scm
+++ b/gnu/tests/install.scm
@@ -21,6 +21,13 @@
21;;; You should have received a copy of the GNU General Public License 21;;; You should have received a copy of the GNU General Public License
22;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. 22;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
23 23
24;;; Commentary:
25;;;
26;;; Test the installation of Guix using the documented approach at the
27;;; command line.
28;;;
29;;; Code:
30
24(define-module (gnu tests install) 31(define-module (gnu tests install)
25 #:use-module (gnu) 32 #:use-module (gnu)
26 #:use-module (gnu bootloader extlinux) 33 #:use-module (gnu bootloader extlinux)
@@ -89,13 +96,6 @@
89 %test-gui-installed-os-encrypted 96 %test-gui-installed-os-encrypted
90 %test-gui-installed-desktop-os-encrypted)) 97 %test-gui-installed-desktop-os-encrypted))
91 98
92;;; Commentary:
93;;;
94;;; Test the installation of Guix using the documented approach at the
95;;; command line.
96;;;
97;;; Code:
98
99(define-os-with-source (%minimal-os %minimal-os-source) 99(define-os-with-source (%minimal-os %minimal-os-source)
100 ;; The OS we want to install. 100 ;; The OS we want to install.
101 (use-modules (gnu) (gnu tests) (srfi srfi-1)) 101 (use-modules (gnu) (gnu tests) (srfi srfi-1))
diff --git a/gnu/tests/linux-modules.scm b/gnu/tests/linux-modules.scm
index 69cb0132670..8f4d79445bd 100644
--- a/gnu/tests/linux-modules.scm
+++ b/gnu/tests/linux-modules.scm
@@ -19,6 +19,12 @@
19;;; You should have received a copy of the GNU General Public License 19;;; You should have received a copy of the GNU General Public License
20;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. 20;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
21 21
22;;; Commentary:
23;;;
24;;; Test <operating-system> kernel-loadable-modules.
25;;;
26;;; Code:
27
22(define-module (gnu tests linux-modules) 28(define-module (gnu tests linux-modules)
23 #:use-module (gnu packages linux) 29 #:use-module (gnu packages linux)
24 #:use-module (gnu services) 30 #:use-module (gnu services)
@@ -40,12 +46,6 @@
40 %test-loadable-kernel-modules-service-1 46 %test-loadable-kernel-modules-service-1
41 %test-loadable-kernel-modules-service-2)) 47 %test-loadable-kernel-modules-service-2))
42 48
43;;; Commentary:
44;;;
45;;; Test <operating-system> kernel-loadable-modules.
46;;;
47;;; Code:
48
49(define* (modules-loaded?-program os modules) 49(define* (modules-loaded?-program os modules)
50 "Return an executable store item that, upon being evaluated, will verify 50 "Return an executable store item that, upon being evaluated, will verify
51that MODULES are actually loaded." 51that MODULES are actually loaded."
diff --git a/gnu/tests/package-management.scm b/gnu/tests/package-management.scm
index c5102fff74d..869494b7e11 100644
--- a/gnu/tests/package-management.scm
+++ b/gnu/tests/package-management.scm
@@ -16,6 +16,12 @@
16;;; You should have received a copy of the GNU General Public License 16;;; You should have received a copy of the GNU General Public License
17;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. 17;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
18 18
19;;; Commentary:
20;;;
21;;; This module provides a test definition for the nix-daemon
22;;;
23;;; Code:
24
19(define-module (gnu tests package-management) 25(define-module (gnu tests package-management)
20 #:use-module (gnu packages base) 26 #:use-module (gnu packages base)
21 #:use-module (gnu packages package-management) 27 #:use-module (gnu packages package-management)
@@ -29,12 +35,6 @@
29 #:use-module (guix packages) 35 #:use-module (guix packages)
30 #:export (%test-nix)) 36 #:export (%test-nix))
31 37
32;;; Commentary:
33;;;
34;;; This module provides a test definition for the nix-daemon
35;;;
36;;; Code:
37
38(define* (run-nix-test name test-os) 38(define* (run-nix-test name test-os)
39 "Run tests in TEST-OS, which has nix-daemon running." 39 "Run tests in TEST-OS, which has nix-daemon running."
40 (define os 40 (define os
diff --git a/gnu/tests/reconfigure.scm b/gnu/tests/reconfigure.scm
index 77cbe16a9ca..1ffb75ad2ac 100644
--- a/gnu/tests/reconfigure.scm
+++ b/gnu/tests/reconfigure.scm
@@ -17,6 +17,13 @@
17;;; You should have received a copy of the GNU General Public License 17;;; You should have received a copy of the GNU General Public License
18;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. 18;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
19 19
20;;; Commentary:
21;;;
22;;; Test in-place system reconfiguration: advancing the system generation on a
23;;; running instance of the Guix System.
24;;;
25;;; Code:
26
20(define-module (gnu tests reconfigure) 27(define-module (gnu tests reconfigure)
21 #:use-module (gnu bootloader) 28 #:use-module (gnu bootloader)
22 #:use-module (gnu services) 29 #:use-module (gnu services)
@@ -38,13 +45,6 @@
38 %test-upgrade-kexec 45 %test-upgrade-kexec
39 %test-install-bootloader)) 46 %test-install-bootloader))
40 47
41;;; Commentary:
42;;;
43;;; Test in-place system reconfiguration: advancing the system generation on a
44;;; running instance of the Guix System.
45;;;
46;;; Code:
47
48(define* (run-switch-to-system-test) 48(define* (run-switch-to-system-test)
49 "Run a test of an OS running SWITCH-SYSTEM-PROGRAM, which creates a new 49 "Run a test of an OS running SWITCH-SYSTEM-PROGRAM, which creates a new
50generation of the system profile." 50generation of the system profile."