summaryrefslogtreecommitdiff
path: root/t/lib-read-tree-m-3way.sh
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-06-08 21:55:35 (GMT)
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-06-08 22:56:09 (GMT)
commitf225b21807a5f6ac589132e4d004e78038d23375 (patch)
tree59bcd6b273780f53869371a44b1376cc671d166e /t/lib-read-tree-m-3way.sh
parent8544a6f1b8e7340924c406d717ac37becd2f6046 (diff)
downloadgit-f225b21807a5f6ac589132e4d004e78038d23375.zip
git-f225b21807a5f6ac589132e4d004e78038d23375.tar.gz
git-f225b21807a5f6ac589132e4d004e78038d23375.tar.bz2
[PATCH] Add read-tree -m 3-way merge tests.
This adds a set of tests to make sure that requirements on existing cache entries are checked when a read-tree -m 3-way merge is run with an already populated index file. Signed-off-by: Junio C Hamano <junkio@cox.net> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 't/lib-read-tree-m-3way.sh')
-rw-r--r--t/lib-read-tree-m-3way.sh14
1 files changed, 14 insertions, 0 deletions
diff --git a/t/lib-read-tree-m-3way.sh b/t/lib-read-tree-m-3way.sh
index d920c6b..d6645b4 100644
--- a/t/lib-read-tree-m-3way.sh
+++ b/t/lib-read-tree-m-3way.sh
@@ -142,3 +142,17 @@ test_expect_success \
'recording branch B tree' \
'tree_B=$(git-write-tree)'
+test_expect_success \
+ 'keep contents of 3 trees for easy access' \
+ 'rm -f .git/index &&
+ git-read-tree $tree_O &&
+ mkdir .orig-O &&
+ git-checkout-cache --prefix=.orig-O/ -f -q -a &&
+ rm -f .git/index &&
+ git-read-tree $tree_A &&
+ mkdir .orig-A &&
+ git-checkout-cache --prefix=.orig-A/ -f -q -a &&
+ rm -f .git/index &&
+ git-read-tree $tree_B &&
+ mkdir .orig-B &&
+ git-checkout-cache --prefix=.orig-B/ -f -q -a'