summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2009-11-24 06:24:01 (GMT)
committerJunio C Hamano <gitster@pobox.com>2009-11-24 06:24:01 (GMT)
commit783cfafb91538c178d78a9f6c7b609e4f06582f8 (patch)
tree242cb4414ba31ea251d701c8ebdf25f01ce3f4f8 /t
parent75a7ea258c0644b79e57cab3a345807f4017dfd2 (diff)
parent0de8b94720501e869a05c52a691985fa4ce69803 (diff)
downloadgit-783cfafb91538c178d78a9f6c7b609e4f06582f8.zip
git-783cfafb91538c178d78a9f6c7b609e4f06582f8.tar.gz
git-783cfafb91538c178d78a9f6c7b609e4f06582f8.tar.bz2
Merge branch 'cc/replace'
* cc/replace: Documentation: talk a little bit about GIT_NO_REPLACE_OBJECTS Documentation: fix typos and spelling in replace documentation replace: use a GIT_NO_REPLACE_OBJECTS env variable
Diffstat (limited to 't')
-rwxr-xr-xt/t6050-replace.sh17
1 files changed, 17 insertions, 0 deletions
diff --git a/t/t6050-replace.sh b/t/t6050-replace.sh
index d4818b4..203ffdb 100755
--- a/t/t6050-replace.sh
+++ b/t/t6050-replace.sh
@@ -77,6 +77,11 @@ test_expect_success 'test --no-replace-objects option' '
git --no-replace-objects show $HASH2 | grep "A U Thor"
'
+test_expect_success 'test GIT_NO_REPLACE_OBJECTS env variable' '
+ GIT_NO_REPLACE_OBJECTS=1 git cat-file commit $HASH2 | grep "author A U Thor" &&
+ GIT_NO_REPLACE_OBJECTS=1 git show $HASH2 | grep "A U Thor"
+'
+
cat >tag.sig <<EOF
object $HASH2
type commit
@@ -202,6 +207,18 @@ test_expect_success 'fetch branch with replacement' '
cd ..
'
+test_expect_success 'bisect and replacements' '
+ git bisect start $HASH7 $HASH1 &&
+ test "$S" = "$(git rev-parse --verify HEAD)" &&
+ git bisect reset &&
+ GIT_NO_REPLACE_OBJECTS=1 git bisect start $HASH7 $HASH1 &&
+ test "$HASH4" = "$(git rev-parse --verify HEAD)" &&
+ git bisect reset &&
+ git --no-replace-objects bisect start $HASH7 $HASH1 &&
+ test "$HASH4" = "$(git rev-parse --verify HEAD)" &&
+ git bisect reset
+'
+
#
#
test_done