aboutsummaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2007-06-02 12:18:51 -0700
committerJunio C Hamano <junkio@cox.net>2007-06-02 12:18:51 -0700
commit17c2929aa2ed999cbefa75ca5e933e1bf53a95bf (patch)
treeae29ccac1e4fd717567db0f1dbabebeee3046d6c /t
parent9b07873a52cc0243c2eddfac2e9c514152b96fb7 (diff)
parentbc8e478a285ff549a3e5182461b064313d400de3 (diff)
downloadgit-17c2929aa2ed999cbefa75ca5e933e1bf53a95bf.tar.gz
git-17c2929aa2ed999cbefa75ca5e933e1bf53a95bf.tar.xz
Merge branch 'sp/pack'
* sp/pack: Style nit - don't put space after function names Ensure the pack index is opened before access Simplify index access condition in count-objects, pack-redundant Test for recent rev-parse $abbrev_sha1 regression rev-parse: Identify short sha1 sums correctly. Attempt to delay prepare_alt_odb during get_sha1 Micro-optimize prepare_alt_odb Lazily open pack index files on demand
Diffstat (limited to 't')
-rwxr-xr-xt/t6101-rev-parse-parents.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/t/t6101-rev-parse-parents.sh b/t/t6101-rev-parse-parents.sh
index 7d354a1fa..b0252b941 100755
--- a/t/t6101-rev-parse-parents.sh
+++ b/t/t6101-rev-parse-parents.sh
@@ -29,5 +29,15 @@ test_expect_success 'final^1^3 not valid' "if git-rev-parse --verify final^1^3;
test_expect_failure '--verify start2^1' 'git-rev-parse --verify start2^1'
test_expect_success '--verify start2^0' 'git-rev-parse --verify start2^0'
+test_expect_success 'repack for next test' 'git repack -a -d'
+test_expect_success 'short SHA-1 works' '
+ start=`git rev-parse --verify start` &&
+ echo $start &&
+ abbrv=`echo $start | sed s/.\$//` &&
+ echo $abbrv &&
+ abbrv=`git rev-parse --verify $abbrv` &&
+ echo $abbrv &&
+ test $start = $abbrv'
+
test_done