summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJohannes Schindelin <Johannes.Schindelin@gmx.de>2007-11-03 15:21:21 (GMT)
committerJunio C Hamano <gitster@pobox.com>2007-11-06 06:47:22 (GMT)
commit620a6cd42ed5ea94684b22714181bf03871733dd (patch)
treea77aaa2feac3be5635d72b54fbc93867b810f32c /t
parentcdf4a751fa728273030651a769f9f45212ff50c9 (diff)
downloadgit-620a6cd42ed5ea94684b22714181bf03871733dd.zip
git-620a6cd42ed5ea94684b22714181bf03871733dd.tar.gz
git-620a6cd42ed5ea94684b22714181bf03871733dd.tar.bz2
builtin-reset: avoid forking "update-index --refresh"
Instead of forking update-index, call refresh_cache() directly. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-xt/t7102-reset.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/t/t7102-reset.sh b/t/t7102-reset.sh
index 506767d..e5c9f30 100755
--- a/t/t7102-reset.sh
+++ b/t/t7102-reset.sh
@@ -418,4 +418,14 @@ test_expect_success 'resetting an unmodified path is a no-op' '
git diff-index --cached --exit-code HEAD
'
+cat > expect << EOF
+file2: needs update
+EOF
+
+test_expect_success '--mixed refreshes the index' '
+ echo 123 >> file2 &&
+ git reset --mixed HEAD > output &&
+ git diff --exit-code expect output
+'
+
test_done