Code

i18n: git-submodule echo + eval_gettext messages
[git.git] / t / t5520-pull.sh
index 0b489f5b1227268c050c1256d105d57d871f5698..0e5eb678ce6b2f4fad79c39947455e5284313ba4 100755 (executable)
@@ -46,6 +46,17 @@ test_expect_success 'pulling into void using master:master' '
        test_cmp file cloned-uho/file
 '
 
+test_expect_success 'pulling into void does not overwrite untracked files' '
+       git init cloned-untracked &&
+       (
+               cd cloned-untracked &&
+               echo untracked >file &&
+               test_must_fail git pull .. master &&
+               echo untracked >expect &&
+               test_cmp expect file
+       )
+'
+
 test_expect_success 'test . as a remote' '
 
        git branch copy master &&
@@ -222,4 +233,11 @@ test_expect_success 'git pull --rebase does not reapply old patches' '
        )
 '
 
+test_expect_success 'git pull --rebase against local branch' '
+       git checkout -b copy2 to-rebase-orig &&
+       git pull --rebase . to-rebase &&
+       test "conflicting modification" = "$(cat file)" &&
+       test file = "$(cat file2)"
+'
+
 test_done