Revision 51a94af845cb3f797abd638478834721d7295af7 authored by Junio C Hamano on 17 October 2008, 06:37:44 UTC, committed by Junio C Hamano on 17 October 2008, 21:35:06 UTC
The test to make sure that checkout fails when --track was asked for and
we cannot set up tracking information in t7201 was wrong, and it turns out
that the implementation for that feature itself was buggy.  This fixes it.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent 8ed0a74
Raw File
t4021-format-patch-signer-mime.sh
#!/bin/sh

test_description='format-patch -s should force MIME encoding as needed'

. ./test-lib.sh

test_expect_success setup '

	>F &&
	git add F &&
	git commit -m initial &&
	echo new line >F &&

	test_tick &&
	git commit -m "This adds some lines to F" F

'

test_expect_success 'format normally' '

	git format-patch --stdout -1 >output &&
	! grep Content-Type output

'

test_expect_success 'format with signoff without funny signer name' '

	git format-patch -s --stdout -1 >output &&
	! grep Content-Type output

'

test_expect_success 'format with non ASCII signer name' '

	GIT_COMMITTER_NAME="はまの ふにおう" \
	git format-patch -s --stdout -1 >output &&
	grep Content-Type output

'

test_expect_success 'attach and signoff do not duplicate mime headers' '

	GIT_COMMITTER_NAME="はまの ふにおう" \
	git format-patch -s --stdout -1 --attach >output &&
	test `grep -ci ^MIME-Version: output` = 1

'

test_done

back to top