summaryrefslogtreecommitdiff
path: root/gnu/packages/check.scm
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2021-09-29 10:13:15 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2021-11-11 12:18:12 -0500
commitdac3ba0d400dc6fb9c06724e282489ea3dcffc70 (patch)
tree5f627fa7826a6ad9b84c851a99f78beca047a784 /gnu/packages/check.scm
parente3f172b1ad48a1772de576086189684ec3978abe (diff)
downloadguix-patches-dac3ba0d400dc6fb9c06724e282489ea3dcffc70.tar
guix-patches-dac3ba0d400dc6fb9c06724e282489ea3dcffc70.tar.gz
gnu: python-pytest-6: Fix version via setuptools-scm.
* gnu/packages/check.scm (python-pytest-6): Fix indentation. [phases]{fix-version}: Rename to... {pretend-version}: ... this. Use the supported setuptools-scm mechanism to manually fix the version string, as suggested upstream.
Diffstat (limited to 'gnu/packages/check.scm')
-rw-r--r--gnu/packages/check.scm8
1 files changed, 3 insertions, 5 deletions
diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm
index e6883dfe0f..8f18b2779e 100644
--- a/gnu/packages/check.scm
+++ b/gnu/packages/check.scm
@@ -981,21 +981,19 @@ standard library.")
(arguments
`(#:phases
(modify-phases %standard-phases
- (add-after 'unpack 'fix-version
+ (add-before 'build 'pretend-version
;; The version string is usually derived via setuptools-scm, but
;; without the git metadata available, the version string is set to
;; '0.0.0'.
(lambda _
- (substitute* "setup.py"
- (("setup\\(\\)")
- (format #f "setup(version=~s)" ,version)))))
+ (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" ,version)))
(replace 'check
(lambda* (#:key (tests? #t) #:allow-other-keys)
(setenv "TERM" "dumb") ;attempt disabling markup tests
(if tests?
(invoke "pytest" "-vv" "-k"
(string-append
- ;; This test involve the /usr directory, and fails.
+ ;; This test involves the /usr directory, and fails.
" not test_argcomplete"
;; These test do not honor the isatty detection and
;; fail.