From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:45374) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jOzsR-0007bn-CO for guix-patches@gnu.org; Thu, 16 Apr 2020 04:28:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jOzsQ-0005Yd-8V for guix-patches@gnu.org; Thu, 16 Apr 2020 04:28:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:54140) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jOzsQ-0005YD-4u for guix-patches@gnu.org; Thu, 16 Apr 2020 04:28:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jOzsQ-0000bW-1g for guix-patches@gnu.org; Thu, 16 Apr 2020 04:28:02 -0400 Subject: [bug#40543] [PATCH v2 5/5] gnu: virt-manager: Work towards enabling some tests. Resent-Message-ID: References: <87wo6n726x.fsf@cbaines.net> <20200415174952.9368-1-mail@cbaines.net> <20200415174952.9368-5-mail@cbaines.net> <873694io3q.fsf@devup.no> From: Christopher Baines In-reply-to: <873694io3q.fsf@devup.no> Date: Thu, 16 Apr 2020 09:27:36 +0100 Message-ID: <87sgh36djb.fsf@cbaines.net> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Marius Bakke Cc: 40543@debbugs.gnu.org --=-=-= Content-Type: text/plain Marius Bakke writes: > Christopher Baines writes: > >> * gnu/packages/virtualization.scm (virt-manager)[arguments]: Set #:test-target >> to "test_ui", replace the 'check phase. >> [native-inputs]: Add some inputs required for running tests. >> --- >> gnu/packages/virtualization.scm | 25 +++++++++++++++++++++---- >> 1 file changed, 21 insertions(+), 4 deletions(-) >> >> diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm >> index be17ec15f0..c8840f345a 100644 >> --- a/gnu/packages/virtualization.scm >> +++ b/gnu/packages/virtualization.scm >> @@ -602,9 +602,10 @@ virtualization library.") >> (build-system python-build-system) >> (arguments >> `(#:use-setuptools? #f ; uses custom distutils 'install' command >> - ;; Some of the tests seem to require network access to install virtual >> - ;; machines. >> - #:tests? #f >> + #:test-target "test_ui" >> + #:tests? #f ; TODO The tests currently fail >> + ; RuntimeError: Loop condition wasn't >> + ; met >> #:imported-modules ((guix build glib-or-gtk-build-system) >> ,@%python-build-system-modules) >> #:modules ((ice-9 match) >> @@ -651,6 +652,16 @@ virtualization library.") >> ,(filter identity paths)))) >> bin-files)) >> #t)) >> + (replace 'check >> + (lambda* (#:key tests? #:allow-other-keys) >> + (when tests? >> + (setenv "HOME" "/tmp") >> + (system "Xvfb :1 &") >> + (setenv "DISPLAY" ":1") >> + ;; Dogtail requires that Assistive Technology support be enabled >> + (setenv "GTK_MODULES" "gail:atk-bridge") >> + (invoke "dbus-run-session" "--" "python" "setup.py" "test_ui")) >> + #t)) >> (add-after 'install 'glib-or-gtk-compile-schemas >> (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-compile-schemas)) >> (add-after 'install 'glib-or-gtk-wrap >> @@ -679,7 +690,13 @@ virtualization library.") >> ("gobject-introspection" ,gobject-introspection) >> ("gtk+" ,gtk+ "bin") ; gtk-update-icon-cache >> ("perl" ,perl) ; pod2man >> - ("intltool" ,intltool))) >> + ("intltool" ,intltool) >> + ;; The following are required for running the tests >> + ("python-dogtail" ,python-dogtail) >> + ("xvfb" ,xorg-server) >> + ("dbus" ,dbus) >> + ("at-spi2-core" ,at-spi2-core) >> + ("gsettings-desktop-schemas" ,gsettings-desktop-schemas))) > > Perhaps we should comment these inputs for now so that they won't > needlessly rebuild this package? Sure, I'll comment them out. > Also, this should use 'xorg-server-for-tests'. I did see xorg-server-for-tests, but the comment said "This package is intended to be used when building GTK". I guess the same reasoning applies though, and it is used for packages other than GTK. I'll make these changes and send some updated patches. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEEPonu50WOcg2XVOCyXiijOwuE9XcFAl6YFvhfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcACgkQXiijOwuE 9Xekiw/9Ev46sjrmZmo3VTjrqYRItONhfeULg5xgLnvzQ8Ud9qEX3JXGGVFxtJ+L T4RumxIoS7NV3XrpqU2I61MrB8AhEhTjBjynJFqp3nl8WzdQVubn/mRNAWfbM7Q1 c48Yn2ZB+Y0dqkFH/MX8CBUUU352Rrdk7kbOPe1SlD/WnSrQsMG2AQkGkp+L4l7C 2uhQJybIyQrOyNDuiYTwsN2jCzIT7GDj1n9HN4rPcRiv5BgQ4UN6w48hjkt2/WTV u7u8QdV7VD5Wjs8/Pg8MOynVW6NR14QMmMaTucOON1/0TFUT3kVmJ7wYrZXQrOKm dfoahWDVpSRMZCq8HO2WZv2UC0VpuE8UEI96AePyXKi5uppa9/3KbESu2vPR7bjT b2IxYJi87TibIXg8Gjfx5jau7sQPLCwlAMxXg3hG1xY8n3I8MQUgYTbxwcnTD/0b 6I4h4jih3Zqf+OEqYxPLa5O+sH4Rg3q3k+gZOqJbZr0q2DRQfQpSMS+tmBWTii9C QntTuE3IhYfjBARJVTdamzS4zAoVj4Df6ZXOgbwPIdd3GSQR2pBw2XW+NCCbkjo7 d6QGPHqz4hUydfUoEgaJegGj5o8EwfFQqPWX5gdR6oRfznJvgEB/QH+rdsFppDPT eVoXxKZ4aJ0fsDaXif/YFXTjHP7WTjb1QC0gUXHjOKmEnIaK9Tk= =R8vD -----END PGP SIGNATURE----- --=-=-=--