aboutsummaryrefslogtreecommitdiff
path: root/contrib/remote-helpers
diff options
context:
space:
mode:
authorFelipe Contreras <felipe.contreras@gmail.com>2013-05-24 21:29:45 -0500
committerJunio C Hamano <gitster@pobox.com>2013-05-28 08:02:03 -0700
commit0bf9ee5720c6d98be8bee93ab3e1a80451de767c (patch)
treedf836d96596056eca2b5c2a0e9121f8da89038dd /contrib/remote-helpers
parentd2c76330286c8bd604f9fbbb7818cecce893b769 (diff)
downloadgit-0bf9ee5720c6d98be8bee93ab3e1a80451de767c.tar.gz
git-0bf9ee5720c6d98be8bee93ab3e1a80451de767c.tar.xz
remote-hg: add test for failed double push
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'contrib/remote-helpers')
-rwxr-xr-xcontrib/remote-helpers/test-hg.sh24
1 files changed, 24 insertions, 0 deletions
diff --git a/contrib/remote-helpers/test-hg.sh b/contrib/remote-helpers/test-hg.sh
index 66e37af09..cbaac51c2 100755
--- a/contrib/remote-helpers/test-hg.sh
+++ b/contrib/remote-helpers/test-hg.sh
@@ -486,4 +486,28 @@ test_expect_failure 'remote big push' '
check_bookmark hgrepo new_bmark ''
'
+test_expect_failure 'remote double failed push' '
+ test_when_finished "rm -rf hgrepo gitrepo*" &&
+
+ (
+ hg init hgrepo &&
+ cd hgrepo &&
+ echo zero > content &&
+ hg add content &&
+ hg commit -m zero &&
+ echo one > content &&
+ hg commit -m one
+ ) &&
+
+ (
+ git clone "hg::hgrepo" gitrepo &&
+ cd gitrepo &&
+ git reset --hard HEAD^ &&
+ echo two > content &&
+ git commit -a -m two &&
+ test_expect_code 1 git push &&
+ test_expect_code 1 git push
+ )
+'
+
test_done