summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Nieder <jrnieder@gmail.com>2013-10-14 11:09:30 -0700
committerJonathan Nieder <jrnieder@gmail.com>2013-10-14 11:09:30 -0700
commit774282d16ab5aa2ec4b8bb7fa4ad83b0622ee778 (patch)
tree9f30c5c347f486237eea76851f373db673c35cc3
parent0e3b378c3ad3d8c5b02c0ab4828ddb9da1a96e57 (diff)
parentb0afc02649285febd6155c1c64d2383b856c1c0e (diff)
downloadgit-774282d16ab5aa2ec4b8bb7fa4ad83b0622ee778.tar.gz
Merge branch 'sb/checkout-test-complex-path'
* sb/checkout-test-complex-path: checkout test: enable test with complex relative path
-rwxr-xr-xt/t2008-checkout-subdir.sh14
1 files changed, 7 insertions, 7 deletions
diff --git a/t/t2008-checkout-subdir.sh b/t/t2008-checkout-subdir.sh
index 3e098ab31e..eadb9434ae 100755
--- a/t/t2008-checkout-subdir.sh
+++ b/t/t2008-checkout-subdir.sh
@@ -58,13 +58,13 @@ test_expect_success 'checkout with simple prefix' '
'
-# This is not expected to work as ls-files was not designed
-# to deal with such. Enable it when ls-files is updated.
-: test_expect_success 'checkout with complex relative path' '
-
- rm file1 &&
- git checkout HEAD -- ../dir1/../dir1/file1 && test -f ./file1
-
+test_expect_success 'checkout with complex relative path' '
+ (
+ cd dir1 &&
+ rm file1 &&
+ git checkout HEAD -- ../dir1/../dir1/file1 &&
+ test "hello" = "$(cat file1)"
+ )
'
test_expect_success 'relative path outside tree should fail' \