]> git.ipfire.org Git - thirdparty/git.git/blobdiff - t/t6436-merge-overwrite.sh
Merge branch 'mk/doc-gitfile-more' into maint-2.43
[thirdparty/git.git] / t / t6436-merge-overwrite.sh
index 84b4aacf496d1df73c6adf83860db430bc1c1c4c..4f4376421e7da28e22f58258061bf58f3a8bc0c8 100755 (executable)
@@ -68,7 +68,8 @@ test_expect_success 'will not overwrite removed file' '
        git commit -m "rm c1.c" &&
        cp important c1.c &&
        test_must_fail git merge c1a &&
-       test_cmp important c1.c
+       test_cmp important c1.c &&
+       rm c1.c  # Do not leave untracked file in way of future tests
 '
 
 test_expect_success 'will not overwrite re-added file' '
@@ -103,12 +104,12 @@ test_expect_success 'will not overwrite unstaged changes in renamed file' '
        if test "$GIT_TEST_MERGE_ALGORITHM" = ort
        then
                test_must_fail git merge c1a >out 2>err &&
-               test_i18ngrep "would be overwritten by merge" err &&
+               test_grep "would be overwritten by merge" err &&
                test_cmp important other.c &&
                test_path_is_missing .git/MERGE_HEAD
        else
                test_must_fail git merge c1a >out &&
-               test_i18ngrep "Refusing to lose dirty file at other.c" out &&
+               test_grep "Refusing to lose dirty file at other.c" out &&
                test_path_is_file other.c~HEAD &&
                test $(git hash-object other.c~HEAD) = $(git rev-parse c1a:c1.c) &&
                test_cmp important other.c