aboutsummaryrefslogtreecommitdiffstats
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2023-11-02 16:53:19 +0900
committerJunio C Hamano <gitster@pobox.com>2023-11-02 16:53:19 +0900
commit2fd4378d64dae6895f1a98b721fe0ed0f0d552b0 (patch)
tree5a2b89f21d681ff391800c916fd27af116184f79 /t
parentMerge branch 'js/systemd-timers-wsl-fix' into maint-2.42 (diff)
parentdiff-lib: fix check_removed when fsmonitor is on (diff)
downloadgit-2fd4378d64dae6895f1a98b721fe0ed0f0d552b0.tar.gz
git-2fd4378d64dae6895f1a98b721fe0ed0f0d552b0.zip
Merge branch 'js/diff-cached-fsmonitor-fix' into maint-2.42
"git diff --cached" codepath did not fill the necessary stat information for a file when fsmonitor knows it is clean and ended up behaving as if it is not clean, which has been corrected. * js/diff-cached-fsmonitor-fix: diff-lib: fix check_removed when fsmonitor is on
Diffstat (limited to 't')
-rwxr-xr-xt/t7527-builtin-fsmonitor.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/t/t7527-builtin-fsmonitor.sh b/t/t7527-builtin-fsmonitor.sh
index 0c241d6c14..78503158fd 100755
--- a/t/t7527-builtin-fsmonitor.sh
+++ b/t/t7527-builtin-fsmonitor.sh
@@ -809,6 +809,11 @@ my_match_and_clean () {
status --porcelain=v2 >actual.without &&
test_cmp actual.with actual.without &&
+ git -C super --no-optional-locks diff-index --name-status HEAD >actual.with &&
+ git -C super --no-optional-locks -c core.fsmonitor=false \
+ diff-index --name-status HEAD >actual.without &&
+ test_cmp actual.with actual.without &&
+
git -C super/dir_1/dir_2/sub reset --hard &&
git -C super/dir_1/dir_2/sub clean -d -f
}