On Mon, Mar 17, 2014 at 7:53 PM, Junio C Hamano <gits...@pobox.com> wrote:
> Benoit Pierre <benoit.pie...@gmail.com> writes:
>> +test_expect_failure 'edit hunk "commit -p -m message"' '
>> +     test_when_finished "rm -f editor_was_started" &&
> Not just "when finished", run "rm -f" here to make sure that the
> file does not exist.  Later other people may add new tests before
> this test piece and affect the state of your throw-away working
> tree, and you would want to protect yourself from their changes.
>> +     echo more >>file &&
>> +     echo e | env GIT_EDITOR="touch editor_was_started" git commit -p -m 
>> commit2 file &&
> Avoid "touch" unless you are interested in the timestamp to be
> updated.  Use ": >editor_was_started" or something like that when
> you are only interested in "it was not there, now it is".
> The same comment applies to the next one.

Isn't the point of using "when finished" to have each test leave the
tree clean after execution, to avoid "bleeding" onto the next test(s)?
Instead of having each test clean after the previous test(s). It seems
to me using both is kind of redundant, no?

A: Because it destroys the flow of conversation.
Q: Why is top posting dumb?
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to