]> git.ipfire.org Git - thirdparty/git.git/commitdiff
t6006: use test-lib.sh definitions
authorPrarit Bhargava <prarit@redhat.com>
Thu, 24 Oct 2019 23:36:15 +0000 (19:36 -0400)
committerJunio C Hamano <gitster@pobox.com>
Fri, 25 Oct 2019 05:09:53 +0000 (14:09 +0900)
Use name and email definitions from test-lib.sh.

Signed-off-by: Prarit Bhargava <prarit@redhat.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t6006-rev-list-format.sh

index cfb74d0e03541e136c46e7c84a7e537e19dc1509..1f7d3f7acc9c35202c3aa25a37f5e055f871bcc0 100755 (executable)
@@ -111,14 +111,14 @@ EOF
 # we don't test relative here
 test_format author %an%n%ae%n%ad%n%aD%n%at <<EOF
 commit $head2
-A U Thor
-author@example.com
+$GIT_AUTHOR_NAME
+$GIT_AUTHOR_EMAIL
 Thu Apr 7 15:13:13 2005 -0700
 Thu, 7 Apr 2005 15:13:13 -0700
 1112911993
 commit $head1
-A U Thor
-author@example.com
+$GIT_AUTHOR_NAME
+$GIT_AUTHOR_EMAIL
 Thu Apr 7 15:13:13 2005 -0700
 Thu, 7 Apr 2005 15:13:13 -0700
 1112911993
@@ -126,14 +126,14 @@ EOF
 
 test_format committer %cn%n%ce%n%cd%n%cD%n%ct <<EOF
 commit $head2
-C O Mitter
-committer@example.com
+$GIT_COMMITTER_NAME
+$GIT_COMMITTER_EMAIL
 Thu Apr 7 15:13:13 2005 -0700
 Thu, 7 Apr 2005 15:13:13 -0700
 1112911993
 commit $head1
-C O Mitter
-committer@example.com
+$GIT_COMMITTER_NAME
+$GIT_COMMITTER_EMAIL
 Thu Apr 7 15:13:13 2005 -0700
 Thu, 7 Apr 2005 15:13:13 -0700
 1112911993
@@ -410,7 +410,7 @@ test_expect_success 'empty email' '
        test_tick &&
        C=$(GIT_AUTHOR_EMAIL= git commit-tree HEAD^{tree} </dev/null) &&
        A=$(git show --pretty=format:%an,%ae,%ad%n -s $C) &&
-       verbose test "$A" = "A U Thor,,Thu Apr 7 15:14:13 2005 -0700"
+       verbose test "$A" = "$GIT_AUTHOR_NAME,,Thu Apr 7 15:14:13 2005 -0700"
 '
 
 test_expect_success 'del LF before empty (1)' '
@@ -495,7 +495,7 @@ test_expect_success '%gd shortens ref name' '
 '
 
 test_expect_success 'reflog identity' '
-       echo "C O Mitter:committer@example.com" >expect &&
+       echo "$GIT_COMMITTER_NAME:$GIT_COMMITTER_EMAIL" >expect &&
        git log -g -1 --format="%gn:%ge" >actual &&
        test_cmp expect actual
 '