Skip to content

Commit 4755fed

Browse files
charvi-077gitster
authored andcommitted
t/t3437: check the author date of fixed up commit
Add '%at' format in the get_author() function and update the test to check that the author date of the fixed up commit is unchanged. Mentored-by: Christian Couder <[email protected]> Mentored-by: Phillip Wood <[email protected]> Helped-by: Eric Sunshine <[email protected]> Signed-off-by: Charvi Mendiratta <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 733ad2e commit 4755fed

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

t/t3437-rebase-fixup-options.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ test_commit_message () {
3333

3434
get_author () {
3535
rev="$1" &&
36-
git log -1 --pretty=format:"%an %ae" "$rev"
36+
git log -1 --pretty=format:"%an %ae %at" "$rev"
3737
}
3838

3939
test_expect_success 'setup' '
@@ -196,6 +196,8 @@ test_expect_success 'multiple fixup -c opens editor once' '
196196
EXPECT_HEADER_COUNT=4 \
197197
git rebase -i $base &&
198198
test_cmp_rev $base HEAD^ &&
199+
get_author HEAD >actual-author &&
200+
test_cmp expected-author actual-author &&
199201
test 1 = $(git show | grep Modified-A3 | wc -l)
200202
'
201203

0 commit comments

Comments
 (0)