Commit graph

3 commits

Author SHA1 Message Date
Johannes Sixt 7f733de04e test-suite: Make test script numbers unique
In order to selectively skip tests, the environment variable GIT_SKIP_TESTS
can be set like this:

  $ GIT_SKIP_TESTS='t1301 t4150.18' make test

That is, its value can contain only the test script numbers, but not the
full script name. Therefore, it is important that the test scripts are
uniquely numbered. This makes it so.

Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-14 12:44:20 -07:00
Junio C Hamano 6bf4f1b4c9 format-patch: generate MIME header as needed even when there is format.header
Earlier, the callchain from pretty_print_commit() down to pp_title_line()
had an unwarranted assumption that the presense of "after_subject"
parameter, means the caller has already output MIME headers for
attachments.  The parameter's primary purpose is to give extra header
lines the caller wants to place after pp_title_line() generates the
"Subject: " line.

This assumption does not hold when the user used the format.header
configuration variable to pass extra headers, and caused a message with
non-ASCII character to lack proper MIME headers (e.g.  8-bit CTE header).
The earlier logic also failed to suppress duplicated MIME headers when
"format-patch -s --attach" is asked for and the signer's name demanded
8-bit clean transport.

This patch fixes the logic by introducing a separate need_8bit_cte
parameter passed down the callchain.  This can have one of these values:

 -1 : we've already done MIME crap and we do not want to add extra header
      to say this is 8bit in pp_title_line();

  0 : we haven't done MIME and we have not seen anything that is 8bit yet;

  1 : we haven't done MIME and we have seen something that is 8bit;
      pp_title_line() must add MIME header.

It adds two tests by Jeff King who independently diagnosed this issue.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-03-15 00:06:06 -07:00
Junio C Hamano aacb8f10a7 test format-patch -s: make sure MIME content type is shown as needed
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-02 17:55:42 -07:00