t1507: abstract away SHA-1-specific constants
Adjust the test so that it uses a variable consisting of the current HEAD instead of a hard-coded hash. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
brian m. carlson committed
Mar 25, 2018 at 19:20 UTC
60e0dc0bd88750fc0a04b9c41dfa4616c131dd99
1 file changed
+3
-2
t/t1507-rev-parse-upstream.sh
+3
-2
@@ -209,8 +209,9 @@ test_expect_success '@{u} works when tracking a local branch' '
209
test refs/heads/master = "$(full_name @{u})"
210
'
211
212
+commit=$(git rev-parse HEAD)
213
cat >expect <<EOF
213
-commit 8f489d01d0cc65c3b0f09504ec50b5ed02a70bd5
214
+commit $commit
215
Reflog: master@{0} (C O Mitter <committer@example.com>)
216
Reflog message: branch: Created from HEAD
217
Author: A U Thor <author@example.com>
@@ -224,7 +225,7 @@ test_expect_success 'log -g other@{u}' '
225
'
226
227
cat >expect <<EOF
227
-commit 8f489d01d0cc65c3b0f09504ec50b5ed02a70bd5
228
+commit $commit
229
Reflog: master@{Thu Apr 7 15:17:13 2005 -0700} (C O Mitter <committer@example.com>)
230
Reflog message: branch: Created from HEAD
231
Author: A U Thor <author@example.com>