aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Elsing <david.elsing@posteo.net>2024-03-23 22:04:45 +0000
committerLudovic Courtès <ludo@gnu.org>2024-06-18 11:34:25 +0200
commit63233f1f0e8a5c8e2e29b781167b15419abd998c (patch)
tree04113a0da9a20261707d197b9b0b32ceec926b79
parent22225dee9bc92a46077410ebd801e12a4daff96e (diff)
downloadguix-63233f1f0e8a5c8e2e29b781167b15419abd998c.tar
guix-63233f1f0e8a5c8e2e29b781167b15419abd998c.tar.gz
gnu: Add python-expecttest.
* gnu/packages/python-check.scm (python-expecttest): New variable.
-rw-r--r--gnu/packages/python-check.scm35
1 files changed, 35 insertions, 0 deletions
diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm
index a6c8aa50fe..3b77495609 100644
--- a/gnu/packages/python-check.scm
+++ b/gnu/packages/python-check.scm
@@ -2193,6 +2193,41 @@ from Python files. It does this by detecting block comments that contain
valid Python syntax that are likely to be commented out code.")
(license license:expat)))
+(define-public python-expecttest
+ (let ((commit "683b09a352cc426851adc2e3a9f46e0ab25e4dee")
+ (revision "0"))
+ (package
+ (name "python-expecttest")
+ (version (git-version "0.2.1" revision commit))
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/ezyang/expecttest")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1djwxp9x1hczzxbimv1b1bmd083am88v27l82nmlkhvzyg2cmpvv"))))
+ (build-system pyproject-build-system)
+ (arguments
+ (list
+ #:phases
+ #~(modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ ;; The test runs tests expected to fail, so the output is
+ ;; confusing
+ (invoke "python3" "test_expecttest.py")))))))
+ (native-inputs (list python-hypothesis poetry))
+ (home-page "https://github.com/ezyang/expecttest")
+ (synopsis "Python module for expect tests")
+ (description "@code{expecttest} is a Python module for expect tests, where
+the initial expected value of a test can be automatically set by running the
+test itself.")
+ (license license:expat))))
+
(define-public python-robber
(package
(name "python-robber")