[PATCH 2 of 2] test: enforce v1 type in 'test-bundle2-remote-changegroup.t'

Pierre-Yves David pierre-yves.david at ens-lyon.org
Sun Oct 18 09:25:13 CDT 2015


# HG changeset patch
# User Pierre-Yves David <pierre-yves.david at fb.com>
# Date 1444960437 -3600
#      Fri Oct 16 02:53:57 2015 +0100
# Node ID 1862194bcab88dbfb1e938298b3f7f2eb2f2cdf4
# Parent  c8b2db1d9fe39a11ab8471b5f814ad92230fcad1
# EXP-Topic generaldelta
# Available At http://hg.netv6.net/marmoute-wip/mercurial/
#              hg pull http://hg.netv6.net/marmoute-wip/mercurial/ -r 1862194bcab8
test: enforce v1 type in 'test-bundle2-remote-changegroup.t'

This bundle command is meant to generate a bundle1, we enforce that to avoid
test's misbehavior when moving to general-delta by default.

diff --git a/tests/test-bundle2-remote-changegroup.t b/tests/test-bundle2-remote-changegroup.t
--- a/tests/test-bundle2-remote-changegroup.t
+++ b/tests/test-bundle2-remote-changegroup.t
@@ -120,11 +120,11 @@ Start a simple HTTP server to serve bund
   > bundle2=$TESTTMP/bundle2.py
   > EOF
 
 Test a pull with an remote-changegroup
 
-  $ hg bundle -R repo --base '0:4' -r '5:7' bundle.hg
+  $ hg bundle -R repo --type v1 --base '0:4' -r '5:7' bundle.hg
   3 changesets found
   $ cat > repo/.hg/bundle2maker << EOF
   > remote-changegroup http://localhost:$HGPORT/bundle.hg bundle.hg
   > EOF
   $ hg clone orig clone -r 3 -r 4
@@ -162,11 +162,11 @@ Test a pull with an remote-changegroup
   
   $ rm -rf clone
 
 Test a pull with an remote-changegroup and a following changegroup
 
-  $ hg bundle -R repo --base 2 -r '3:4' bundle2.hg
+  $ hg bundle -R repo --type v1 --base 2 -r '3:4' bundle2.hg
   2 changesets found
   $ cat > repo/.hg/bundle2maker << EOF
   > remote-changegroup http://localhost:$HGPORT/bundle2.hg bundle2.hg
   > changegroup 0:4 5:7
   > EOF
@@ -210,11 +210,11 @@ Test a pull with an remote-changegroup a
   
   $ rm -rf clone
 
 Test a pull with a changegroup followed by an remote-changegroup
 
-  $ hg bundle -R repo --base '0:4' -r '5:7' bundle3.hg
+  $ hg bundle -R repo --type v1 --base '0:4' -r '5:7' bundle3.hg
   3 changesets found
   $ cat > repo/.hg/bundle2maker << EOF
   > changegroup 000000000000 :4
   > remote-changegroup http://localhost:$HGPORT/bundle3.hg bundle3.hg
   > EOF
@@ -258,13 +258,13 @@ Test a pull with a changegroup followed 
   
   $ rm -rf clone
 
 Test a pull with two remote-changegroups and a changegroup
 
-  $ hg bundle -R repo --base 2 -r '3:4' bundle4.hg
+  $ hg bundle -R repo --type v1 --base 2 -r '3:4' bundle4.hg
   2 changesets found
-  $ hg bundle -R repo --base '3:4' -r '5:6' bundle5.hg
+  $ hg bundle -R repo --type v1 --base '3:4' -r '5:6' bundle5.hg
   2 changesets found
   $ cat > repo/.hg/bundle2maker << EOF
   > remote-changegroup http://localhost:$HGPORT/bundle4.hg bundle4.hg
   > remote-changegroup http://localhost:$HGPORT/bundle5.hg bundle5.hg
   > changegroup 0:6 7
@@ -314,11 +314,11 @@ Test a pull with two remote-changegroups
   
   $ rm -rf clone
 
 Hash digest tests
 
-  $ hg bundle -R repo -a bundle6.hg
+  $ hg bundle -R repo --type v1 -a bundle6.hg
   8 changesets found
 
   $ cat > repo/.hg/bundle2maker << EOF
   > raw-remote-changegroup {'url': 'http://localhost:$HGPORT/bundle6.hg', 'size': 1663, 'digests': 'sha1', 'digest:sha1': '2c880cfec23cff7d8f80c2f12958d1563cbdaba6'}
   > EOF


More information about the Mercurial-devel mailing list