X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;ds=sidebyside;f=t%2Ft2018-checkout-branch.sh;h=2741262369e40a05cdc6732e4c9e6f04acb63bba;hb=969fe57b844a514747c1d5d66e0698dc53ed473d;hp=75874e85dfbcae8ea9634693a93524841b741559;hpb=afb6b561e3dad13df5d9df9731751a3d310c0854;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