X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=t%2Ft2018-checkout-branch.sh;h=2741262369e40a05cdc6732e4c9e6f04acb63bba;hb=8a557bb77fc009b00f7952f0d3d6ebd33079f70e;hp=75874e85dfbcae8ea9634693a93524841b741559;hpb=e63f87a6f7a4e55f50e67b112f26d9a1e4e7f3ab;p=git.git diff --git a/t/t2018-checkout-branch.sh b/t/t2018-checkout-branch.sh index 75874e85d..274126236 100755 --- a/t/t2018-checkout-branch.sh +++ b/t/t2018-checkout-branch.sh @@ -189,12 +189,13 @@ test_expect_success 'checkout -b ' ' test_cmp expect actual ' -test_expect_success 'checkout -B to the current branch fails before merging' ' +test_expect_success 'checkout -B to the current branch works' ' git checkout branch1 && + git checkout -B branch1-scratch && + setup_dirty_mergeable && - git commit -mfooble && - test_must_fail git checkout -B branch1 initial && - test_must_fail test_dirty_mergeable + git checkout -B branch1-scratch initial && + test_dirty_mergeable ' test_done