X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=t%2Ft5516-fetch-push.sh;h=b5417cc951b1cecbbde613fa572387f362e889d1;hb=3f263099fca47c278e696fbc0f0d5525318eae0a;hp=b69cf574d7e9a272ea70864e87ed6556abe94f13;hpb=f124fe3061d4da53bad3a03fd2875141e8a7a48e;p=git.git diff --git a/t/t5516-fetch-push.sh b/t/t5516-fetch-push.sh index b69cf574d..b5417cc95 100755 --- a/t/t5516-fetch-push.sh +++ b/t/t5516-fetch-push.sh @@ -979,4 +979,20 @@ test_expect_success 'push --porcelain --dry-run rejected' ' test_cmp .git/foo .git/bar ' +test_expect_success 'push --prune' ' + mk_test heads/master heads/second heads/foo heads/bar && + git push --prune testrepo && + check_push_result $the_commit heads/master && + check_push_result $the_first_commit heads/second && + ! check_push_result $the_first_commit heads/foo heads/bar +' + +test_expect_success 'push --prune refspec' ' + mk_test tmp/master tmp/second tmp/foo tmp/bar && + git push --prune testrepo "refs/heads/*:refs/tmp/*" && + check_push_result $the_commit tmp/master && + check_push_result $the_first_commit tmp/second && + ! check_push_result $the_first_commit tmp/foo tmp/bar +' + test_done