]> git.ipfire.org Git - thirdparty/git.git/blobdiff - t/t7064-wtstatus-pv2.sh
Sync with 2.34.5
[thirdparty/git.git] / t / t7064-wtstatus-pv2.sh
index 5a0c5685bd087324674ca9189b0b1e6d68e47035..11884d2fc36911cea7f82a1257e35434de61500c 100755 (executable)
@@ -4,10 +4,6 @@ test_description='git status --porcelain=v2
 
 This test exercises porcelain V2 output for git status.'
 
-
-GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master
-export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
-
 . ./test-lib.sh
 
 
@@ -113,6 +109,21 @@ test_expect_success 'after first commit, create unstaged changes' '
        test_cmp expect actual
 '
 
+test_expect_success 'after first commit, stash existing changes' '
+       cat >expect <<-EOF &&
+       # branch.oid $H0
+       # branch.head initial-branch
+       # stash 2
+       EOF
+
+       test_when_finished "git stash pop && git stash pop" &&
+
+       git stash -- file_x &&
+       git stash &&
+       git status --porcelain=v2 --branch --show-stash --untracked-files=no >actual &&
+       test_cmp expect actual
+'
+
 test_expect_success 'after first commit but omit untracked files and branch' '
        cat >expect <<-EOF &&
        1 .M N... 100644 100644 100644 $OID_X $OID_X file_x