diff options
author | Ludovic Courtès <ludo@gnu.org> | 2014-12-29 19:11:09 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2014-12-29 21:18:12 +0100 |
commit | 8b385969cf30c6646ec3cf78f1ee69e03029b7a1 (patch) | |
tree | 37adbcbc1570f90a46ed4765b81ace44448445c7 /guix/tests.scm | |
parent | 907c98acbbf533715983c61a1e53cb29a52c4bef (diff) | |
download | gnu-guix-8b385969cf30c6646ec3cf78f1ee69e03029b7a1.tar gnu-guix-8b385969cf30c6646ec3cf78f1ee69e03029b7a1.tar.gz |
tests: Factorize the 'dummy-package' macro.
* guix/tests.scm (dummy-package): New macro.
* tests/lint.scm (dummy-package): Remove.
* tests/packages.scm (dummy-package): Remove.
Diffstat (limited to 'guix/tests.scm')
-rw-r--r-- | guix/tests.scm | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/guix/tests.scm b/guix/tests.scm index 022679902a..82ae7e2084 100644 --- a/guix/tests.scm +++ b/guix/tests.scm @@ -27,7 +27,8 @@ #:export (open-connection-for-tests random-text random-bytevector - with-derivation-narinfo)) + with-derivation-narinfo + dummy-package)) ;;; Commentary: ;;; @@ -120,6 +121,15 @@ substituter's viewpoint." (lambda () body ...))) +(define-syntax-rule (dummy-package name* extra-fields ...) + "Return a \"dummy\" package called NAME*, with all its compulsory fields +initialized with default values, and with EXTRA-FIELDS set as specified." + (package extra-fields ... + (name name*) (version "0") (source #f) + (build-system gnu-build-system) + (synopsis #f) (description #f) + (home-page #f) (license #f))) + ;; Local Variables: ;; eval: (put 'call-with-derivation-narinfo 'scheme-indent-function 1) ;; End: |