From 2915a7604a8dd1ac81ff4c8557b46c9f6048228c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 17 Jun 2020 13:19:15 -0400 Subject: gnu: supercollider: Enable all tests. * gnu/packages/audio.scm (supercollider)[phases]{set-home, prepare-x}: New phases. {disable-broken-tests}: Delete phase. {patch-scclass-dir}: Adapt accordingly. [native-inputs]: Add xorg-server-for-tests. --- gnu/packages/audio.scm | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) (limited to 'gnu') diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index 4a6798c854..74ef7111c3 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -2379,22 +2379,14 @@ link REQUIRED)")) ;emacs-scel #:phases (modify-phases %standard-phases - ;; Some tests are broken (see: - ;; https://github.com/supercollider/supercollider/issues/3555 and - ;; https://github.com/supercollider/supercollider/issues/1736 - (add-after 'rm-bundled-libs 'disable-broken-tests + ;; HOME must be defined otherwise supercollider throws a "ERROR: + ;; Primitive '_FileMkDir' failed." error when generating the doc. + ;; The graphical tests also hang without it. + (add-after 'unpack 'set-home-directory (lambda _ - (substitute* "testsuite/server/supernova/CMakeLists.txt" - (("server_test.cpp") - "") - (("perf_counter_test.cpp") - "")) - (substitute* "testsuite/CMakeLists.txt" - (("add_subdirectory\\(sclang\\)") - "")) - (delete-file "testsuite/sclang/CMakeLists.txt") + (setenv "HOME" (getcwd)) #t)) - (add-after 'disable-broken-tests 'patch-scclass-dir + (add-after 'unpack 'patch-scclass-dir (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (scclass-dir @@ -2406,6 +2398,11 @@ link REQUIRED)")) "\\(DirName::Resource\\) / CLASS_LIB_DIR_NAME")) (string-append "Path(\"" scclass-dir "\")"))) #t))) + (add-before 'build 'prepare-x + (lambda _ + (system "Xvfb &") + (setenv "DISPLAY" ":0") + #t)) (add-before 'install 'install-ide (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) @@ -2418,7 +2415,8 @@ link REQUIRED)")) (native-inputs `(("ableton-link" ,ableton-link) ("pkg-config" ,pkg-config) - ("qttools" ,qttools))) + ("qttools" ,qttools) + ("xorg-server" ,xorg-server-for-tests))) (inputs `(("jack" ,jack-1) ("libsndfile" ,libsndfile) -- cgit 1.4.1