t6020: Add a testcase for modify/delete + directory/file conflict
[gitweb.git] / t / t3404-rebase-interactive.sh
index 56891e6c74c0883236074b39fdbd83a96c5c9658..7d20a74c5ca1331ff241d1596bcb114e48a5907d 100755 (executable)
@@ -101,10 +101,10 @@ test_expect_success 'rebase -i with the exec command' '
 
 test_expect_success 'rebase -i with the exec command runs from tree root' '
        git checkout master &&
-       mkdir subdir && cd subdir &&
+       mkdir subdir && (cd subdir &&
        FAKE_LINES="1 exec_>touch-subdir" \
-               git rebase -i HEAD^ &&
-       cd .. &&
+               git rebase -i HEAD^
+       ) &&
        test_path_is_file touch-subdir &&
        rm -fr subdir
 '
@@ -211,8 +211,9 @@ test_expect_success 'abort with error when new base cannot be checked out' '
        git rm --cached file1 &&
        git commit -m "remove file in base" &&
        test_must_fail git rebase -i master > output 2>&1 &&
-       grep "Untracked working tree file .file1. would be overwritten" \
+       grep "The following untracked working tree files would be overwritten by checkout:" \
                output &&
+       grep "file1" output &&
        test_path_is_missing .git/rebase-merge &&
        git reset --hard HEAD^
 '
@@ -698,13 +699,19 @@ test_expect_success 'set up commits with funny messages' '
        git commit -a -m "end with slash\\" &&
        echo >>file1 &&
        test_tick &&
+       git commit -a -m "something (\000) that looks like octal" &&
+       echo >>file1 &&
+       test_tick &&
+       git commit -a -m "something (\n) that looks like a newline" &&
+       echo >>file1 &&
+       test_tick &&
        git commit -a -m "another commit"
 '
 
 test_expect_success 'rebase-i history with funny messages' '
        git rev-list A..funny >expect &&
        test_tick &&
-       FAKE_LINES="1 2" git rebase -i A &&
+       FAKE_LINES="1 2 3 4" git rebase -i A &&
        git rev-list A.. >actual &&
        test_cmp expect actual
 '