diff options
author | Ludovic Courtès <ludo@gnu.org> | 2023-05-31 23:50:06 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2023-05-31 23:50:06 +0200 |
commit | 654fcf9971bb01389d577be07c6ec0f68940c743 (patch) | |
tree | 59ff22f02c9b265adc4b8f596b9924b586895248 /tests/hexpm.scm | |
parent | 9f7cd1fcaf99c8e8430d0b29335220701664dc54 (diff) |
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.
Diffstat (limited to 'tests/hexpm.scm')
-rw-r--r-- | tests/hexpm.scm | 126 |
1 files changed, 63 insertions, 63 deletions
diff --git a/tests/hexpm.scm b/tests/hexpm.scm index e9f899f166..5df9af0ca6 100644 --- a/tests/hexpm.scm +++ b/tests/hexpm.scm @@ -139,22 +139,22 @@ "source") (_ (error "url-fetch got unexpected URL: " url)))))))) (match (hexpm->guix-package "bla") - (('package - ('name "erlang-bla") - ('version "1.5.0") - ('source - ('origin - ('method 'url-fetch) - ('uri ('hexpm-uri "bla" 'version)) - ('sha256 - ('base32 - "0zcl4dgcmqwl1g5xb901pd6dz61r1xgmac9mqlwvh022paa6gks1")))) - ('build-system 'rebar-build-system) - ('inputs ('list 'erlang-blubb 'erlang-fasel)) - ('synopsis "A cool package") - ('description "This package provides a cool package") - ('home-page "https://hex.pm/packages/bla") - ('license ('list 'license:expat 'license:asl2.0))) + (`(package + (name "erlang-bla") + (version "1.5.0") + (source + (origin + (method url-fetch) + (uri (hexpm-uri "bla" version)) + (sha256 + (base32 + "0zcl4dgcmqwl1g5xb901pd6dz61r1xgmac9mqlwvh022paa6gks1")))) + (build-system rebar-build-system) + (inputs (list erlang-blubb erlang-fasel)) + (synopsis "A cool package") + (description "This package provides a cool package") + (home-page "https://hex.pm/packages/bla") + (license (list license:expat license:asl2.0))) #t) (x (pk 'fail x #f)))))) @@ -199,53 +199,53 @@ "fasel-source") (_ (error "url-fetch got unexpected URL: " url)))))))) (match (hexpm-recursive-import "bla") - ((('package - ('name "erlang-blubb") - ('version "0.3.1") - ('source - ('origin - ('method 'url-fetch) - ('uri ('hexpm-uri "blubb" 'version)) - ('sha256 - ('base32 - "17y88b5y8ld7s1c2bcwwwa04pf1cl4402i9zk3inna221ps3ppj2")))) - ('build-system 'mix-build-system) - ('inputs ('list 'erlang-fasel)) - ('synopsis "Another cool package") - ('description "Another cool package") - ('home-page "https://hex.pm/packages/blubb") - ('license 'license:expat)) - ('package - ('name "erlang-fasel") - ('version "1.2.1") - ('source - ('origin - ('method 'url-fetch) - ('uri ('hexpm-uri "fasel" 'version)) - ('sha256 - ('base32 - "1k6d70mxwqgq78jrbr7yqnw187yki74jnagybi7nacrj4a67qjha")))) - ('build-system 'gnu-build-system) - ('synopsis "Yet another cool package") - ('description "Yet another cool package") - ('home-page "https://hex.pm/packages/fasel") - ('license "GPL")) - ('package - ('name "erlang-bla") - ('version "1.5.0") - ('source - ('origin - ('method 'url-fetch) - ('uri ('hexpm-uri "bla" 'version)) - ('sha256 - ('base32 - "0d3gj746c4swbb1m6ycylxb239jsavvdcizag6bfbg2aqccxwij8")))) - ('build-system 'rebar-build-system) - ('inputs ('list 'erlang-blubb 'erlang-fasel)) - ('synopsis "A cool package") - ('description "This package provides a cool package") - ('home-page "https://hex.pm/packages/bla") - ('license ('list 'license:expat 'license:asl2.0)))) + (`((package + (name "erlang-blubb") + (version "0.3.1") + (source + (origin + (method url-fetch) + (uri (hexpm-uri "blubb" version)) + (sha256 + (base32 + "17y88b5y8ld7s1c2bcwwwa04pf1cl4402i9zk3inna221ps3ppj2")))) + (build-system mix-build-system) + (inputs (list erlang-fasel)) + (synopsis "Another cool package") + (description "Another cool package") + (home-page "https://hex.pm/packages/blubb") + (license license:expat)) + (package + (name "erlang-fasel") + (version "1.2.1") + (source + (origin + (method url-fetch) + (uri (hexpm-uri "fasel" version)) + (sha256 + (base32 + "1k6d70mxwqgq78jrbr7yqnw187yki74jnagybi7nacrj4a67qjha")))) + (build-system gnu-build-system) + (synopsis "Yet another cool package") + (description "Yet another cool package") + (home-page "https://hex.pm/packages/fasel") + (license "GPL")) + (package + (name "erlang-bla") + (version "1.5.0") + (source + (origin + (method url-fetch) + (uri (hexpm-uri "bla" version)) + (sha256 + (base32 + "0d3gj746c4swbb1m6ycylxb239jsavvdcizag6bfbg2aqccxwij8")))) + (build-system rebar-build-system) + (inputs (list erlang-blubb erlang-fasel)) + (synopsis "A cool package") + (description "This package provides a cool package") + (home-page "https://hex.pm/packages/bla") + (license (list license:expat license:asl2.0)))) #t) (x (pk 'fail x #f)))))) |