tests: drop obsolete "hginit" alias in remotefilelog tests
authorMartin von Zweigbergk <martinvonz@google.com>
Fri, 09 Nov 2018 08:19:08 -0800
changeset 53309 95a079ea1e19067eb7b75e06a7e51354fe283afa
parent 53308 ad71c792a8d842377c62c4237552621bc815e09e
child 53310 def08813b29036fa697f8fafb4bd639ac6dfd500
push id1070
push usergszorc@mozilla.com
push dateSat, 10 Nov 2018 00:17:04 +0000
tests: drop obsolete "hginit" alias in remotefilelog tests Differential Revision: https://phab.mercurial-scm.org/D5247
tests/remotefilelog-library.sh
tests/test-remotefilelog-bad-configs.t
tests/test-remotefilelog-bgprefetch.t
tests/test-remotefilelog-blame.t
tests/test-remotefilelog-bundle2-legacy.t
tests/test-remotefilelog-bundle2.t
tests/test-remotefilelog-bundles.t
tests/test-remotefilelog-clone-tree.t
tests/test-remotefilelog-clone.t
tests/test-remotefilelog-corrupt-cache.t
tests/test-remotefilelog-gc.t
tests/test-remotefilelog-gcrepack.t
tests/test-remotefilelog-http.t
tests/test-remotefilelog-keepset.t
tests/test-remotefilelog-linknodes.t
tests/test-remotefilelog-local.t
tests/test-remotefilelog-log.t
tests/test-remotefilelog-partial-shallow.t
tests/test-remotefilelog-permissions.t
tests/test-remotefilelog-prefetch.t
tests/test-remotefilelog-pull-noshallow.t
tests/test-remotefilelog-push-pull.t
tests/test-remotefilelog-repack-fast.t
tests/test-remotefilelog-repack.t
tests/test-remotefilelog-sparse.t
tests/test-remotefilelog-tags.t
tests/test-remotefilelog-wireproto.t
--- a/tests/remotefilelog-library.sh
+++ b/tests/remotefilelog-library.sh
@@ -55,23 +55,16 @@ url=$lfsdir
 [remotefilelog]
 reponame=master
 datapackversion=1
 [phases]
 publish=False
 EOF
 }
 
-hginit() {
-  local name
-  name=$1
-  shift
-  hg init $name $@
-}
-
 clearcache() {
   rm -rf $CACHEDIR/*
 }
 
 mkcommit() {
   echo "$1" > "$1"
   hg add "$1"
   hg ci -m "$1"
--- a/tests/test-remotefilelog-bad-configs.t
+++ b/tests/test-remotefilelog-bad-configs.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ echo y > y
   $ echo z > z
--- a/tests/test-remotefilelog-bgprefetch.t
+++ b/tests/test-remotefilelog-bgprefetch.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ echo z > z
   $ hg commit -qAm x
--- a/tests/test-remotefilelog-blame.t
+++ b/tests/test-remotefilelog-blame.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ hg commit -qAm x
   $ echo y >> x
--- a/tests/test-remotefilelog-bundle2-legacy.t
+++ b/tests/test-remotefilelog-bundle2-legacy.t
@@ -35,17 +35,17 @@ without changegroup2 support
   >     for k in ['01', '02', '03']:
   >         if not packermap.get(k):
   >             raise error.Abort("packermap doesn't have key '%s'!" % k)
   > 
   >     del packermap['02']
   >     deleted = True
   > EOF
 
-  $ hginit master
+  $ hg init master
   $ grep generaldelta master/.hg/requires
   generaldelta
   $ cd master
 preferuncompressed = False so that we can make both generaldelta and non-generaldelta clones
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > [experimental]
--- a/tests/test-remotefilelog-bundle2.t
+++ b/tests/test-remotefilelog-bundle2.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ grep generaldelta master/.hg/requires
   generaldelta
   $ cd master
 preferuncompressed = False so that we can make both generaldelta and non-generaldelta clones
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > [experimental]
--- a/tests/test-remotefilelog-bundles.t
+++ b/tests/test-remotefilelog-bundles.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ hg commit -qAm x
   $ echo y >> x
--- a/tests/test-remotefilelog-clone-tree.t
+++ b/tests/test-remotefilelog-clone-tree.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ echo treemanifest >> .hg/requires
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
 # uppercase directory name to test encoding
   $ mkdir -p A/B
--- a/tests/test-remotefilelog-clone.t
+++ b/tests/test-remotefilelog-clone.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ hg commit -qAm x
 
--- a/tests/test-remotefilelog-corrupt-cache.t
+++ b/tests/test-remotefilelog-corrupt-cache.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ echo y > y
   $ echo z > z
--- a/tests/test-remotefilelog-gc.t
+++ b/tests/test-remotefilelog-gc.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > serverexpiration=-1
   > EOF
   $ echo x > x
   $ hg commit -qAm x
--- a/tests/test-remotefilelog-gcrepack.t
+++ b/tests/test-remotefilelog-gcrepack.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ hg commit -qAm x
   $ echo y > y
--- a/tests/test-remotefilelog-http.t
+++ b/tests/test-remotefilelog-http.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ echo y > y
   $ hg commit -qAm x
--- a/tests/test-remotefilelog-keepset.t
+++ b/tests/test-remotefilelog-keepset.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > serverexpiration=-1
   > EOF
   $ echo x > x
   $ hg commit -qAm x
--- a/tests/test-remotefilelog-linknodes.t
+++ b/tests/test-remotefilelog-linknodes.t
@@ -1,16 +1,16 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
 # Tests for the complicated linknode logic in remotefilelog.py::ancestormap()
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > serverexpiration=-1
   > EOF
   $ echo x > x
   $ hg commit -qAm x
@@ -54,17 +54,17 @@
 
   $ cd ..
 
 # Reset repos
   $ clearcache
 
   $ rm -rf master
   $ rm -rf shallow
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > serverexpiration=-1
   > EOF
   $ echo x > x
   $ hg commit -qAm x
--- a/tests/test-remotefilelog-local.t
+++ b/tests/test-remotefilelog-local.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ echo y > y
   $ echo z > z
--- a/tests/test-remotefilelog-log.t
+++ b/tests/test-remotefilelog-log.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ hg commit -qAm x
   $ mkdir dir
--- a/tests/test-remotefilelog-partial-shallow.t
+++ b/tests/test-remotefilelog-partial-shallow.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > foo
   $ echo y > bar
   $ hg commit -qAm one
--- a/tests/test-remotefilelog-permissions.t
+++ b/tests/test-remotefilelog-permissions.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ hg commit -qAm x
 
--- a/tests/test-remotefilelog-prefetch.t
+++ b/tests/test-remotefilelog-prefetch.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ echo z > z
   $ hg commit -qAm x
--- a/tests/test-remotefilelog-pull-noshallow.t
+++ b/tests/test-remotefilelog-pull-noshallow.t
@@ -13,17 +13,17 @@ non-shallow repositories.
   > from mercurial import extensions
   > def extsetup(ui):
   >     remotefilelog = extensions.find('remotefilelog')
   >     remotefilelog.onetimeclientsetup(ui)
   > EOF
 
 Set up the master repository to pull from.
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ hg commit -qAm x
 
--- a/tests/test-remotefilelog-push-pull.t
+++ b/tests/test-remotefilelog-push-pull.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ hg commit -qAm x
 
@@ -177,17 +177,17 @@ the server supports our custom getfiles 
   (run 'hg update' to get a working copy)
 
   $ cd ..
 
 # Test pushing from shallow to shallow with multiple manifests introducing the
 # same filenode. Test this by constructing two separate histories of file 'c'
 # that share a file node and verifying that the history works after pushing.
 
-  $ hginit multimf-master
+  $ hg init multimf-master
   $ hgcloneshallow ssh://user@dummy/multimf-master multimf-shallow -q
   $ hgcloneshallow ssh://user@dummy/multimf-master multimf-shallow2 -q
   $ cd multimf-shallow
   $ echo a > a
   $ hg commit -qAm a
   $ echo b > b
   $ hg commit -qAm b
   $ echo c > c
--- a/tests/test-remotefilelog-repack-fast.t
+++ b/tests/test-remotefilelog-repack-fast.t
@@ -3,17 +3,17 @@
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
   $ cat >> $HGRCPATH <<EOF
   > [remotefilelog]
   > fastdatapack=True
   > EOF
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > serverexpiration=-1
   > EOF
   $ echo x > x
   $ hg commit -qAm x
--- a/tests/test-remotefilelog-repack.t
+++ b/tests/test-remotefilelog-repack.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > serverexpiration=-1
   > EOF
   $ echo x > x
   $ hg commit -qAm x
--- a/tests/test-remotefilelog-sparse.t
+++ b/tests/test-remotefilelog-sparse.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ echo z > z
   $ hg commit -qAm x1
--- a/tests/test-remotefilelog-tags.t
+++ b/tests/test-remotefilelog-tags.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > foo
   $ echo y > bar
   $ hg commit -qAm one
--- a/tests/test-remotefilelog-wireproto.t
+++ b/tests/test-remotefilelog-wireproto.t
@@ -1,14 +1,14 @@
   $ PYTHONPATH=$TESTDIR/..:$PYTHONPATH
   $ export PYTHONPATH
 
   $ . "$TESTDIR/remotefilelog-library.sh"
 
-  $ hginit master
+  $ hg init master
   $ cd master
   $ cat >> .hg/hgrc <<EOF
   > [remotefilelog]
   > server=True
   > EOF
   $ echo x > x
   $ hg commit -qAm x
   $ echo y >> x