diff options
author | Johannes Schindelin <Johannes.Schindelin@gmx.de> | 2007-11-03 14:33:01 +0000 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2007-11-05 22:47:22 -0800 |
commit | cdf4a751fa728273030651a769f9f45212ff50c9 (patch) | |
tree | 50b4cc8b762614039347b5749b6e10ad3b9993a2 /t/t7102-reset.sh | |
parent | fe61935007b6803ce116e233316e4ff51de02be6 (diff) | |
download | git-cdf4a751fa728273030651a769f9f45212ff50c9.tar.gz git-cdf4a751fa728273030651a769f9f45212ff50c9.tar.xz |
builtin-reset: do not call "ls-files --unmerged"
Since reset is a builtin now, it can use the full power of libgit.a
and check for unmerged entries itself.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7102-reset.sh')
-rwxr-xr-x | t/t7102-reset.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/t/t7102-reset.sh b/t/t7102-reset.sh index cea9afb76..506767d2d 100755 --- a/t/t7102-reset.sh +++ b/t/t7102-reset.sh @@ -59,6 +59,15 @@ test_expect_success 'giving a non existing revision should fail' ' check_changes 3ec39651e7f44ea531a5de18a9fa791c0fd370fc ' +test_expect_success 'reset --soft with unmerged index should fail' ' + touch .git/MERGE_HEAD && + echo "100644 44c5b5884550c17758737edcced463447b91d42b 1 un" | + git update-index --index-info && + ! git reset --soft HEAD && + rm .git/MERGE_HEAD && + git rm --cached -- un +' + test_expect_success \ 'giving paths with options different than --mixed should fail' ' ! git reset --soft -- first && |