aboutsummaryrefslogtreecommitdiff
path: root/gnu/tests/base.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2016-06-20 22:34:13 +0200
committerLudovic Courtès <ludo@gnu.org>2016-06-20 23:50:46 +0200
commit98b65b5ff6b1dea0ad58b0f47dd163c32d0cbf6e (patch)
tree7aa29f770d1ff50aea95af404324061ec708cd03 /gnu/tests/base.scm
parent2a6ba870867e31a32faca0dbf0e062bf9f5c0d78 (diff)
downloadpatches-98b65b5ff6b1dea0ad58b0f47dd163c32d0cbf6e.tar
patches-98b65b5ff6b1dea0ad58b0f47dd163c32d0cbf6e.tar.gz
tests: Add a mechanism to describe and discover system tests.
* gnu/tests.scm (<system-test>): New record type. (write-system-test, test-modules, fold-system-tests) (all-system-tests): New procedures. * gnu/tests/base.scm (%test-basic-os): Turn into a <system-test>. * gnu/tests/install.scm (%test-installed-os): Likewise. * build-aux/run-system-tests.scm (%system-tests): Remove. (run-system-tests): Use 'all-system-tests'.
Diffstat (limited to 'gnu/tests/base.scm')
-rw-r--r--gnu/tests/base.scm30
1 files changed, 17 insertions, 13 deletions
diff --git a/gnu/tests/base.scm b/gnu/tests/base.scm
index b417bc4bda..3dfa28f7f5 100644
--- a/gnu/tests/base.scm
+++ b/gnu/tests/base.scm
@@ -161,16 +161,20 @@ info --version")
#:modules '((gnu build marionette))))
(define %test-basic-os
- ;; Monadic derivation that instruments %SIMPLE-OS, runs it in a VM, and runs
- ;; a series of basic functionality tests.
- (mlet* %store-monad ((os -> (marionette-operating-system
- %simple-os
- #:imported-modules '((gnu services herd)
- (guix combinators))))
- (run (system-qemu-image/shared-store-script
- os #:graphic? #f)))
- ;; XXX: Add call to 'virtualized-operating-system' to get the exact same
- ;; set of services as the OS produced by
- ;; 'system-qemu-image/shared-store-script'.
- (run-basic-test (virtualized-operating-system os '())
- #~(list #$run))))
+ (system-test
+ (name "basic")
+ (description
+ "Instrument %SIMPLE-OS, run it in a VM, and runs a series of basic
+functionality tests.")
+ (value
+ (mlet* %store-monad ((os -> (marionette-operating-system
+ %simple-os
+ #:imported-modules '((gnu services herd)
+ (guix combinators))))
+ (run (system-qemu-image/shared-store-script
+ os #:graphic? #f)))
+ ;; XXX: Add call to 'virtualized-operating-system' to get the exact same
+ ;; set of services as the OS produced by
+ ;; 'system-qemu-image/shared-store-script'.
+ (run-basic-test (virtualized-operating-system os '())
+ #~(list #$run))))))