File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -860,6 +860,27 @@ test_expect_success 'checkout -p patch editing of added file' '
860
860
)
861
861
'
862
862
863
+ test_expect_success EXPENSIVE ' add -i with a lot of files' '
864
+ git reset --hard &&
865
+ x160=0123456789012345678901234567890123456789 &&
866
+ x160=$x160$x160$x160$x160 &&
867
+ y= &&
868
+ i=0 &&
869
+ while test $i -le 200
870
+ do
871
+ name=$(printf "%s%03d" $x160 $i) &&
872
+ echo $name >$name &&
873
+ git add -N $name &&
874
+ y="${y}y$LF" &&
875
+ i=$(($i+1)) ||
876
+ break
877
+ done &&
878
+ echo "$y" | git add -p -- . &&
879
+ git diff --cached >staged &&
880
+ test_line_count = 1407 staged &&
881
+ git reset --hard
882
+ '
883
+
863
884
test_expect_success ' show help from add--helper' '
864
885
git reset --hard &&
865
886
cat >expect <<-EOF &&
You can’t perform that action at this time.
0 commit comments