We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 7551391 + 5b32708 commit 1a9fe45Copy full SHA for 1a9fe45
t/t7607-merge-overwrite.sh
@@ -156,4 +156,20 @@ test_expect_success 'will not overwrite untracked file on unborn branch' '
156
test_cmp important c0.c
157
'
158
159
+test_expect_success 'set up unborn branch and content' '
160
+ git symbolic-ref HEAD refs/heads/unborn &&
161
+ rm -f .git/index &&
162
+ echo foo > tracked-file &&
163
+ git add tracked-file &&
164
+ echo bar > untracked-file
165
+'
166
+
167
+test_expect_failure 'will not clobber WT/index when merging into unborn' '
168
+ git merge master &&
169
+ grep foo tracked-file &&
170
+ git show :tracked-file >expect &&
171
+ grep foo expect &&
172
+ grep bar untracked-file
173
174
175
test_done
0 commit comments