[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#47906] [PATCH 19/22] gnu: Add python-pytest-xvfb.
From: |
Vinicius Monego |
Subject: |
[bug#47906] [PATCH 19/22] gnu: Add python-pytest-xvfb. |
Date: |
Tue, 20 Apr 2021 05:22:43 +0000 |
* gnu/packages/python-check.scm (python-pytest-xvfb): New variable.
---
gnu/packages/python-check.scm | 37 +++++++++++++++++++++++++++++++++++
1 file changed, 37 insertions(+)
diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm
index db09197d41..427b32c5cf 100644
--- a/gnu/packages/python-check.scm
+++ b/gnu/packages/python-check.scm
@@ -39,6 +39,7 @@
#:use-module (gnu packages qt)
#:use-module (gnu packages web)
#:use-module (gnu packages xml)
+ #:use-module (gnu packages xorg)
#:use-module (guix utils)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
@@ -831,6 +832,42 @@ for the @code{pytest} framework.")
rounds that are calibrated to the chosen timer.")
(license license:bsd-2)))
+(define-public python-pytest-xvfb
+ (package
+ (name "python-pytest-xvfb")
+ (version "2.0.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "pytest-xvfb" version))
+ (sha256
+ (base32 "1kyq5rg27dsnj7dc6x9y7r8vwf8rc88y2ppnnw6r96alw0nn9fn4"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:test-target "pytest"
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'build 'prepare-tests
+ (lambda _
+ (system "Xvfb &")
+ (setenv "DISPLAY" ":0")
+
+ ;; This test is meant to run on Windows.
+ (delete-file "tests/test_xvfb_windows.py")
+ #t)))))
+ (native-inputs
+ `(("python-pytest" ,python-pytest)
+ ("python-pytest-runner" ,python-pytest-runner)
+ ("xorg-server" ,xorg-server-for-tests)))
+ (propagated-inputs
+ `(("python-pyvirtualdisplay"
+ ,python-pyvirtualdisplay)))
+ (home-page "https://github.com/The-Compiler/pytest-xvfb")
+ (synopsis "Pytest plugin to run Xvfb for tests")
+ (description
+ "This package provides a Pytest plugin to run Xvfb for tests.")
+ (license license:expat)))
+
(define-public python-pytest-services
(package
(name "python-pytest-services")
--
2.31.1
- [bug#47906] [PATCH 11/22] gnu: python-language-server: Enable tests., (continued)
- [bug#47906] [PATCH 10/22] gnu: Add python-qstylizer., Vinicius Monego, 2021/04/20
- [bug#47906] [PATCH 08/22] gnu: python-qtconsole: Enable tests., Vinicius Monego, 2021/04/20
- [bug#47906] [PATCH 14/22] gnu: Add python-qtsass., Vinicius Monego, 2021/04/20
- [bug#47906] [PATCH 16/22] gnu: Add python-easyprocess., Vinicius Monego, 2021/04/20
- [bug#47906] [PATCH 15/22] gnu: python-qdarkstyle: Update to 3.0.2., Vinicius Monego, 2021/04/20
- [bug#47906] [PATCH 19/22] gnu: Add python-pytest-xvfb.,
Vinicius Monego <=
- [bug#47906] [PATCH 17/22] gnu: Add python-entrypoint2., Vinicius Monego, 2021/04/20
- [bug#47906] [PATCH 18/22] gnu: Add python-pyvirtualdisplay., Vinicius Monego, 2021/04/20
- [bug#47906] [PATCH 21/22] gnu: python-language-server: Relax dependency versions., Vinicius Monego, 2021/04/20
- [bug#47906] [PATCH 20/22] gnu: python-diff-match-patch: Update to 20200713., Vinicius Monego, 2021/04/20
- [bug#47906] [PATCH 22/22] gnu: Add spyder., Vinicius Monego, 2021/04/20