Thread (41 messages) flat view 41 messages, 3 authors, 2021-02-10
STALE2010d

Revision v1 of 3 in this series.

Revisions (3)
  1. v1 [diff vs current]
  2. v1 current
  3. v1 [diff vs current]

[PATCH v2 07/11] t/t3437: check author date of the fixed up commit

From: Charvi Mendiratta <hidden>
Date: 2021-02-08 19:31:55
Subsystem: the rest · Maintainer: Linus Torvalds

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 [off-list ref]
Mentored-by: Phillip Wood [off-list ref]
Helped-by: Eric Sunshine [off-list ref]
Signed-off-by: Charvi Mendiratta <redacted>
---
 t/t3437-rebase-fixup-options.sh | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/t/t3437-rebase-fixup-options.sh b/t/t3437-rebase-fixup-options.sh
index 242770a3ec..180fc50248 100755
--- a/t/t3437-rebase-fixup-options.sh
+++ b/t/t3437-rebase-fixup-options.sh
@@ -33,7 +33,7 @@ test_commit_message () {

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

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

--
2.29.0.rc1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help