Merge branch 'da/mergetool-xxdiff-hotkey'
[gitweb.git] / t / t9800-git-p4-basic.sh
index 0730f18d0f83f4145c5a0dbfde784d71bdc57a1d..093e9bd586da55cc27412422d58551a6830bd1a3 100755 (executable)
@@ -257,6 +257,26 @@ test_expect_success 'submit from detached head' '
        )
 '
 
+test_expect_success 'submit from worktree' '
+       test_when_finished cleanup_git &&
+       git p4 clone --dest="$git" //depot &&
+       (
+               cd "$git" &&
+               git worktree add ../worktree-test
+       ) &&
+       (
+               cd "$git/../worktree-test" &&
+               test_commit "worktree-commit" &&
+               git config git-p4.skipSubmitEdit true &&
+               git p4 submit
+       ) &&
+       (
+               cd "$cli" &&
+               p4 sync &&
+               test_path_is_file worktree-commit.t
+       )
+'
+
 test_expect_success 'kill p4d' '
        kill_p4d
 '