aboutsummaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorEfraim Flashner <efraim@flashner.co.il>2018-12-24 22:18:37 +0200
committerEfraim Flashner <efraim@flashner.co.il>2018-12-24 22:19:40 +0200
commit7e48e8492a09bffa17814d00189c0c73b227a0db (patch)
treecfff388ec2af1bd09aed4b594e92b441ebeb9d45 /gnu
parent3619b26196f92bd9dbf265ddea65cc3884b92965 (diff)
downloadpatches-7e48e8492a09bffa17814d00189c0c73b227a0db.tar
patches-7e48e8492a09bffa17814d00189c0c73b227a0db.tar.gz
gnu: gcompris-qt: Enable tests.
* gnu/packages/education.scm (gcompris-qt)[arguments]: Add custom phase to start X server before tests. Add configure flag to build tests. Enable tests. [native-inputs]: Add xorg-server.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/education.scm15
1 files changed, 12 insertions, 3 deletions
diff --git a/gnu/packages/education.scm b/gnu/packages/education.scm
index 3487db436b..ef97d58a84 100644
--- a/gnu/packages/education.scm
+++ b/gnu/packages/education.scm
@@ -41,6 +41,7 @@
#:use-module (gnu packages qt)
#:use-module (gnu packages sdl)
#:use-module (gnu packages texinfo)
+ #:use-module (gnu packages xorg)
#:use-module (gnu packages xml)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
@@ -129,6 +130,13 @@ of categories with some of the activities available in that category.
(arguments
`(#:phases
(modify-phases %standard-phases
+ (add-before 'check 'start-xorg-server
+ (lambda* (#:key inputs #:allow-other-keys)
+ ;; The test suite requires a running X server.
+ (system (string-append (assoc-ref inputs "xorg-server")
+ "/bin/Xvfb :1 &"))
+ (setenv "DISPLAY" ":1")
+ #t))
(add-after 'install 'wrap-executable
(lambda* (#:key inputs outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
@@ -145,13 +153,14 @@ of categories with some of the activities available in that category.
'("qtdeclarative" "qtgraphicaleffects"
"qtmultimedia" "qtquickcontrols"))))
#t))))
- #:configure-flags (list "-DQML_BOX2D_MODULE=disabled")
- #:tests? #f)) ; no test target
+ #:configure-flags (list "-DQML_BOX2D_MODULE=disabled"
+ "-DBUILD_TESTING=TRUE")))
(native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules)
("gettext" ,gettext-minimal)
("perl" ,perl)
- ("qttools" ,qttools)))
+ ("qttools" ,qttools)
+ ("xorg-server" ,xorg-server)))
(inputs
`(("python-2" ,python-2)
("qtbase" ,qtbase)