From: Matthieu Moy <Matthieu.Moy@grenoble-inp•fr>
To: Tanay Abhra <tanayabh@gmail•com>
Cc: git@vger•kernel.org, Ramkumar Ramachandra <artagnon@gmail•com>,
Eric Sunshine <sunshine@sunshineco•com>,
Jeff King <peff@peff•net>, Torsten Bogershausen <tboegi@web•de>
Subject: Re: [PATCH v1] Git config cache & special querying api utilizing the cache
Date: Wed, 11 Jun 2014 16:01:32 +0200 [thread overview]
Message-ID: <vpqr42v35qb.fsf@anie.imag.fr> (raw)
In-Reply-To: <1402318146-5062-1-git-send-email-tanayabh@gmail.com> (Tanay Abhra's message of "Mon, 9 Jun 2014 05:49:05 -0700")
Tanay Abhra <tanayabh@gmail•com> writes:
> I have run the tests and debug the code using custom functions and it works
> fine.
I understand that you wrote the custom functions for you, but didn't
include them in the patch, right?
If so, wouldn't it make sense to include these as unit-tests for your
code? See what Git already does with test-*.c, e.g.
$ git grep test-hashmap
.gitignore:/test-hashmap
Documentation/technical/api-hashmap.txt:See test-hashmap.c for an example using arbitrary-length strings as keys.
Makefile:TEST_PROGRAMS_NEED_X += test-hashmap
t/t0011-hashmap.sh: echo "$1" | test-hashmap $3 > actual &&
t/t0011-hashmap.sh: cat in | test-hashmap > out &&
test-hashmap.c: * Usage: time echo "perfhashmap method rounds" | test-hashmap
for examples. The resulting binary would be a good candidate for
valgrind --leak-check=full.
The tests are not just for you, they are also:
* For reviewers, to show an example of correct usage of the new API,
* For people of the future, to avoid regressions.
--
Matthieu Moy
http://www-verimag.imag.fr/~moy/
prev parent reply other threads:[~2014-06-11 14:01 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-09 12:49 [PATCH v1] Git config cache & special querying api utilizing the cache Tanay Abhra
2014-06-09 12:49 ` [PATCH v1] config: Add hashtable for config parsing & retrival Tanay Abhra
2014-06-09 14:24 ` Matthieu Moy
2014-06-10 11:51 ` Eric Sunshine
2014-06-10 11:27 ` Eric Sunshine
2014-06-10 12:35 ` Tanay Abhra
2014-06-10 21:28 ` Eric Sunshine
2014-06-10 11:45 ` Eric Sunshine
2014-06-10 12:37 ` Tanay Abhra
2014-06-10 23:30 ` Eric Sunshine
2014-06-11 14:01 ` Matthieu Moy [this message]
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=vpqr42v35qb.fsf@anie.imag.fr \
--to=matthieu.moy@grenoble-inp$(echo .)fr \
--cc=artagnon@gmail$(echo .)com \
--cc=git@vger$(echo .)kernel.org \
--cc=peff@peff$(echo .)net \
--cc=sunshine@sunshineco$(echo .)com \
--cc=tanayabh@gmail$(echo .)com \
--cc=tboegi@web$(echo .)de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox