mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-27 14:52:05 -05:00
gnu: clitest: Use G-expressions.
* gnu/packages/check.scm (clitest)[arguments]: Rewrite as gexp. While here, respect TESTS? in check phase.
This commit is contained in:
parent
696e34e721
commit
31ff6a525d
1 changed files with 24 additions and 23 deletions
|
@ -220,30 +220,31 @@ (define-public clitest
|
||||||
"1p745mxiq3hgi3ywfljs5sa1psi06awwjxzw0j9c2xx1b09yqv4a"))))
|
"1p745mxiq3hgi3ywfljs5sa1psi06awwjxzw0j9c2xx1b09yqv4a"))))
|
||||||
(build-system gnu-build-system)
|
(build-system gnu-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
`(#:phases
|
(list
|
||||||
(modify-phases %standard-phases
|
#:phases
|
||||||
;; This package is distributed as a single shell script and comes
|
#~(modify-phases %standard-phases
|
||||||
;; without a proper build system.
|
;; This package is distributed as a single shell script and comes
|
||||||
(delete 'configure)
|
;; without a proper build system.
|
||||||
(delete 'build)
|
(delete 'configure)
|
||||||
(replace 'check
|
(delete 'build)
|
||||||
(lambda _
|
(replace 'check
|
||||||
(substitute* "test.md"
|
(lambda* (#:key tests? #:allow-other-keys)
|
||||||
;; One test looks for an error from grep in the form "grep: foo",
|
(when tests?
|
||||||
;; but our grep returns the absolute file name on errors. Adjust
|
(substitute* "test.md"
|
||||||
;; the test to cope with that.
|
;; One test looks for an error from grep in the form "grep: foo",
|
||||||
(("sed 's/\\^e\\*grep: \\.\\*/")
|
;; but our grep returns the absolute file name on errors. Adjust
|
||||||
"sed 's/.*e*grep: .*/"))
|
;; the test to cope with that.
|
||||||
|
(("sed 's/\\^e\\*grep: \\.\\*/")
|
||||||
|
"sed 's/.*e*grep: .*/"))
|
||||||
|
|
||||||
(setenv "HOME" "/tmp")
|
(setenv "HOME" "/tmp")
|
||||||
(invoke "./clitest" "test.md")))
|
(invoke "./clitest" "test.md"))))
|
||||||
(replace 'install
|
(replace 'install
|
||||||
(lambda* (#:key outputs #:allow-other-keys)
|
(lambda _
|
||||||
(let ((out (assoc-ref outputs "out")))
|
(install-file "clitest" (string-append #$output "/bin"))
|
||||||
(install-file "clitest" (string-append out "/bin"))
|
(install-file "README.md"
|
||||||
(install-file "README.md"
|
(string-append #$output "/share/doc/clitest-"
|
||||||
(string-append out "/share/doc/clitest-"
|
#$(package-version this-package))))))))
|
||||||
,version))))))))
|
|
||||||
(native-inputs
|
(native-inputs
|
||||||
(list perl)) ;for tests
|
(list perl)) ;for tests
|
||||||
(inputs
|
(inputs
|
||||||
|
|
Loading…
Reference in a new issue