git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Paul Tan <pyokagan@gmail.com>
To: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>
Cc: Git List <git@vger.kernel.org>,
	Johannes Schindelin <johannes.schindelin@gmx.de>,
	Duy Nguyen <pclouds@gmail.com>
Subject: Re: [PATCH/RFC/GSOC] make git-pull a builtin
Date: Sat, 21 Mar 2015 21:23:21 +0800	[thread overview]
Message-ID: <CACRoPnQp-3RGAPmoo1aM2KUA-phi138J2o82FwP9annM+xvOXA@mail.gmail.com> (raw)
In-Reply-To: <vpqwq2eyyzl.fsf@anie.imag.fr>

Hi,

Thanks for the review, though I would like to work on the proposal now
before the deadline passes :)

On Thu, Mar 19, 2015 at 1:52 AM, Matthieu Moy
<Matthieu.Moy@grenoble-inp.fr> wrote:
> Paul Tan <pyokagan@gmail.com> writes:
>
>> Ideally, I think the solution is to
>> improve the test suite and make it as comprehensive as possible, but
>> writing a comprehensive test suite may be too time consuming.
>
> time-consuming, but also very beneficial since the code would end up
> being better tested. For sure, a rewrite is a good way to break stuff,
> but anything untested can also be broken by mistake rather easily at any
> time.
>
> I'd suggest doing a bit of manual mutation testing: take your C code,
> comment-out a few lines of code, see if the tests still pass, and if
> they do, add a failing test that passes again once you uncomment the
> code.

Maybe code coverage tools could help here so we only need to focus on
the code paths that are untested by the test suite. At the minimum,
all of the non-trivial code paths in both the shell script and the
converted builtin must be covered by tests. This should help to
eliminate most sources of breakages. Anything further than that would
require an experienced understanding of all the possible important
inputs to be tested, which I personally feel would make the project
quite tedious.

I see git already has gcov support. For shell scripts, maybe kcov[1]
could be used. With some slight code changes, I managed to generate a
report for the git-pull tests[2] which should at least provide a good
starting point for how the tests can be improved.

[1] http://simonkagstrom.github.io/kcov/
[2] <http://www.googledrive.com/host/0B4O2AiYulllpfmJlTW4xT050OVVicnNWWS02dm52aTJ2TFIwQ2QwdWh0VHotSkU4eUNNWjg>

Regards,
Paul

  reply	other threads:[~2015-03-21 13:23 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-17 13:57 [PATCH/RFC/GSOC] make git-pull a builtin Paul Tan
2015-03-18  8:38 ` Stephen Robin
2015-03-18  9:24   ` Johannes Schindelin
2015-03-18  9:00 ` Johannes Schindelin
2015-03-21 14:00   ` Paul Tan
2015-03-21 17:27     ` Johannes Schindelin
2015-03-18 17:52 ` Matthieu Moy
2015-03-21 13:23   ` Paul Tan [this message]
2015-03-21 17:35     ` Johannes Schindelin
2015-03-22 17:39       ` Paul Tan
2015-03-23  9:07         ` Johannes Schindelin
2015-03-23 10:18     ` Duy Nguyen
2015-03-24 15:58       ` Paul Tan
2015-03-18 22:26 ` Junio C Hamano
2015-03-21 13:40   ` Paul Tan

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CACRoPnQp-3RGAPmoo1aM2KUA-phi138J2o82FwP9annM+xvOXA@mail.gmail.com \
    --to=pyokagan@gmail.com \
    --cc=Matthieu.Moy@grenoble-inp.fr \
    --cc=git@vger.kernel.org \
    --cc=johannes.schindelin@gmx.de \
    --cc=pclouds@gmail.com \
    /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 public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).