# HG changeset patch
# User David M. Carr  <david@carrclan.us>
# Date 1349655591 14400
#      Sun Oct 07 20:19:51 2012 -0400
# Node ID c0c1a96ef56df4589e63a4e60b67fc5ccd0f4c34
# Parent  4bc39fd24db3869e3e427b3f6b5d2f895a2bfa56
tests: add workflow coverage for push with no changes

test-bookmark-workflow.t now skips all Mercurial versions below 2.1, as the
return code is different, and it's more important for this test to accurately
show that we match the behavior of current Mercurial than that all versions
behave the same.

diff --git a/tests/test-bookmark-workflow.t b/tests/test-bookmark-workflow.t
--- a/tests/test-bookmark-workflow.t
+++ b/tests/test-bookmark-workflow.t
@@ -15,6 +15,10 @@
 Bail if the user does not have dulwich
   $ python -c 'import dulwich, dulwich.repo' || exit 80
 
+Skip if Mercurial < 2.1; workflow was different before that
+  $ python -c 'from mercurial import util ; assert \
+  >  util.version() != "unknown" and util.version() >= "2.1"' || exit 80
+
   $ echo "[extensions]" >> $HGRCPATH
   $ echo "hggit=$(echo $(dirname $TESTDIR))/hggit" >> $HGRCPATH
 
@@ -105,6 +109,11 @@
   searching for changes
   no changes found
   [1]
+  $ hg push
+  pushing to $TESTTMP/hgremoterepo
+  searching for changes
+  no changes found
+  [1]
   $ cd ..
   $ cd hggitlocalrepo
   $ hg outgoing
@@ -112,4 +121,9 @@
   searching for changes
   no changes found
   [1]
+  $ hg push
+  pushing to $TESTTMP/gitremoterepo
+  searching for changes
+  no changes found
+  [1]
   $ cd ..