From: ludo@gnu.org (Ludovic Courtès)
To: Arun Isaac <arunisaac@systemreboot.net>
Cc: 26889@debbugs.gnu.org
Subject: bug#26889: Tests for emacs-clojure-mode
Date: Fri, 12 May 2017 23:48:13 +0200 [thread overview]
Message-ID: <8737c97nmq.fsf@gnu.org> (raw)
In-Reply-To: <864f5ab5.AEAAKEHRjrgAAAAAAAAAAAOtUOAAAAACwQwAAAAAAAW9WABZFK4O@mailjet.com> (Arun Isaac's message of "Fri, 12 May 2017 00:01:05 +0530")
Hi Arun,
Arun Isaac <arunisaac@systemreboot.net> skribis:
> From 52c39f301978ec7081f43466aec5211185eb43dd Mon Sep 17 00:00:00 2001
> From: Arun Isaac <arunisaac@systemreboot.net>
> Date: Thu, 11 May 2017 23:23:30 +0530
> Subject: [PATCH 1/4] gnu: Add emacs-ansi.
>
> * gnu/packages/emacs.scm (emacs-ansi): New variable.
LGTM.
> From 75b5e7ae59be84680077dca4942eecca275f7c8c Mon Sep 17 00:00:00 2001
> From: Arun Isaac <arunisaac@systemreboot.net>
> Date: Thu, 11 May 2017 23:24:43 +0530
> Subject: [PATCH 2/4] gnu: Add emacs-commander.
>
> * gnu/packages/emacs.scm (emacs-commander): New variable.
LGTM.
> From 77491a17bbbaef34d94bd37732a031988796aa66 Mon Sep 17 00:00:00 2001
> From: Arun Isaac <arunisaac@systemreboot.net>
> Date: Thu, 11 May 2017 23:25:27 +0530
> Subject: [PATCH 3/4] gnu: Add ert-runner.
>
> * gnu/packages/emacs.scm (ert-runner): New variable.
[...]
> +(define-public ert-runner
> + (let ((dependencies
> + `(("emacs-ansi" ,emacs-ansi)
> + ("emacs-commander" ,emacs-commander)
> + ("emacs-dash" ,emacs-dash)
> + ("emacs-f" ,emacs-f)
> + ("emacs-s" ,emacs-s)
> + ("emacs-shut-up" ,emacs-shut-up))))
[...]
> + (wrap-program (string-append out "/bin/ert-runner")
> + (list "EMACSLOADPATH" ":" '=
> + (append
> + (map (lambda (name version)
> + (string-append
> + (assoc-ref inputs name)
> + "/share/emacs/site-lisp/guix.d/"
> + (substring name 6) "-" version))
> + ',(map car dependencies)
> + ',(map (compose package-version cadr) dependencies))
> + (list ""))))))))))
I’d suggest ‘match’ instead of car/cadr, and ‘string-drop’
instead of ‘substring’.
Also, I think we should avoid relying on the fact that input labels are
equal to the corresponding package name. For instance, procedures like
‘package-for-guile-2.2’ mechanically rewrite packages and change their
names, but they do not change the labels.
That gives something like
,(match dependencies
(((labels packages) ...)
`(map (lambda (label package version)
(string-append (assoc-ref inputs label)
"/share/…" (string-drop package 6)
"-" version))
',labels
',(map package-name packages)
',(map package-version packages))))
Last thing: this phase should return #t after the call to
‘wrap-program’.
OK with changes along these lines!
> From 8b9bfa1f646d7211514395400adb1abaf4c2369c Mon Sep 17 00:00:00 2001
> From: Arun Isaac <arunisaac@systemreboot.net>
> Date: Thu, 11 May 2017 23:28:53 +0530
> Subject: [PATCH 4/4] gnu: emacs-clojure-mode: Enable tests.
>
> * gnu/packages/emacs.scm (emacs-clojure-mode)[arguments]: Add 'check' phase.
> [native-inputs]: Add emacs-dash, emacs-s and ert-runner.
LGTM.
Thank you!
Ludo’.
next prev parent reply other threads:[~2017-05-12 21:49 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-11 18:31 bug#26889: Tests for emacs-clojure-mode Arun Isaac
2017-05-12 21:48 ` Ludovic Courtès [this message]
2017-05-13 5:08 ` Arun Isaac
2017-05-13 9:25 ` Alex Kost
2017-05-13 15:24 ` Arun Isaac
[not found] ` <cu7d1bd1gzd.fsf@systemreboot.net>
2017-05-14 12:09 ` Arun Isaac
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8737c97nmq.fsf@gnu.org \
--to=ludo@gnu.org \
--cc=26889@debbugs.gnu.org \
--cc=arunisaac@systemreboot.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.