1
0
mirror of https://git.savannah.gnu.org/git/guix.git synced 2026-05-28 12:01:49 +02:00

tests: Use quasiquoted 'match' patterns for package sexps.

Turns out it's easier to read.

* tests/cpan.scm ("cpan->guix-package"): Use a quasiquoted pattern.
* tests/elpa.scm (eval-test-with-elpa): Likewise.
* tests/gem.scm ("gem->guix-package")
("gem->guix-package with a specific version")
("gem-recursive-import")
("gem-recursive-import with a specific version"): Likewise.
* tests/hexpm.scm ("hexpm-recursive-import"): Likewise.
* tests/opam.scm ("opam->guix-package"): Likewise.
* tests/pypi.scm ("pypi->guix-package, no wheel")
("pypi->guix-package, wheels")
("pypi->guix-package, no usable requirement file.")
("pypi->guix-package, package name contains \"-\" followed by digits"):
Likewise.
* tests/texlive.scm ("texlive->guix-package"): Likewise.
This commit is contained in:
Ludovic Courtès
2023-05-31 23:50:06 +02:00
parent 9f7cd1fcaf
commit 654fcf9971
7 changed files with 278 additions and 284 deletions
+14 -14
View File
@@ -66,20 +66,20 @@
(200 "fake tarball contents"))
(parameterize ((current-http-proxy (%local-url)))
(match (elpa->guix-package pkg #:repo 'gnu/http)
(('package
('name "emacs-auctex")
('version "11.88.6")
('source
('origin
('method 'url-fetch)
('uri ('string-append
"http://elpa.gnu.org/packages/auctex-" 'version ".tar"))
('sha256 ('base32 (? string? hash)))))
('build-system 'emacs-build-system)
('home-page "http://www.gnu.org/software/auctex/")
('synopsis "Integrated environment for *TeX*")
('description "This is the description.")
('license 'license:gpl3+))
(`(package
(name "emacs-auctex")
(version "11.88.6")
(source
(origin
(method url-fetch)
(uri (string-append
"http://elpa.gnu.org/packages/auctex-" version ".tar"))
(sha256 (base32 ,(? string? hash)))))
(build-system emacs-build-system)
(home-page "http://www.gnu.org/software/auctex/")
(synopsis "Integrated environment for *TeX*")
(description "This is the description.")
(license license:gpl3+))
#t)
(x
(pk 'fail x #f))))))