tests/test-evolve-serveronly.t
author Pierre-Yves David <pierre-yves.david@octobus.net>
Tue, 10 Oct 2017 16:22:21 +0200
branchstable
changeset 3050 6603d5655192
parent 3000 bd7e8be29542
child 3001 67b59d1657cf
child 3013 945a0989e41b
permissions -rw-r--r--
obsfate: add a test with user both current and other This will help highlight change in the next changesets.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2046
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
     1
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
     2
  $ . ${TESTDIR}/testlib/pythonpath.sh
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
     3
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
     4
  $ cat >> $HGRCPATH <<EOF
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
     5
  > [defaults]
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
     6
  > amend=-d "0 0"
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
     7
  > [web]
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
     8
  > push_ssl = false
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
     9
  > allow_push = *
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    10
  > [phases]
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    11
  > publish = False
1356
aff6bc2a6b2d test: adapt to change in mercurial core
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1248
diff changeset
    12
  > [experimental]
1721
d3429d25e0cb test: also use 'devel.legacy.exchange=bundle1' in test
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1522
diff changeset
    13
  > bundle2-exp=False # < Mercurial-4.0
d3429d25e0cb test: also use 'devel.legacy.exchange=bundle1' in test
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1522
diff changeset
    14
  > [devel]
d3429d25e0cb test: also use 'devel.legacy.exchange=bundle1' in test
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1522
diff changeset
    15
  > legacy.exchange=bundle1
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    16
  > [extensions]
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    17
  > EOF
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    18
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    19
  $ mkcommit() {
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    20
  >    echo "$1" > "$1"
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    21
  >    hg add "$1"
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    22
  >    hg ci -m "add $1"
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    23
  > }
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    24
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    25
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    26
  $ hg init server
2046
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    27
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    28
Try the multiple ways to setup the extension
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    29
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    30
  $ hg -R server log --config 'extensions.evolve.serveronly='
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    31
  $ hg -R server log --config "extensions.evolve.serveronly=${SRCDIR}/hgext3rd/evolve/serveronly.py"
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    32
  $ PYTHONPATH=$HGTEST_ORIG_PYTHONPATH hg -R server log --config "extensions.evolve.serveronly=${SRCDIR}/hgext3rd/evolve/serveronly.py"
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    33
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    34
setup repo
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    35
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    36
  $ echo "[extensions]" >> ./server/.hg/hgrc
2046
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    37
  $ echo "evolve.serveronly=" >> ./server/.hg/hgrc
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    38
  $ hg serve -R server -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log --traceback
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    39
  $ cat hg.pid >> $DAEMON_PIDS
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    40
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    41
  $ hg clone http://localhost:$HGPORT/ client
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    42
  no changes found
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    43
  updating to branch default
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    44
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1087
82873af0cf10 test-simple4server: add error output for http
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1042
diff changeset
    45
  $ cat ./errors.log
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    46
  $ echo "[extensions]" >> ./client/.hg/hgrc
2046
994d81caec68 test: update test to check for various way to import the serveronly things
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1838
diff changeset
    47
  $ echo "evolve=" >> ./client/.hg/hgrc
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    48
  $ cp -r client other
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    49
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    50
Smoke testing
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    51
===============
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    52
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    53
  $ cd client
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    54
  $ mkcommit 0
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    55
  $ mkcommit a
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    56
  $ hg push
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    57
  pushing to http://localhost:$HGPORT/
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    58
  searching for changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    59
  remote: adding changesets
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    60
  remote: adding manifests
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    61
  remote: adding file changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    62
  remote: added 2 changesets with 2 changes to 2 files
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    63
  $ hg pull
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    64
  pulling from http://localhost:$HGPORT/
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    65
  searching for changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    66
  no changes found
1087
82873af0cf10 test-simple4server: add error output for http
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1042
diff changeset
    67
  $ cat ../errors.log
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    68
  $ hg pull -R ../other
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    69
  pulling from http://localhost:$HGPORT/
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    70
  requesting all changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    71
  adding changesets
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    72
  adding manifests
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    73
  adding file changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    74
  added 2 changesets with 2 changes to 2 files
1038
45c4739e85dc evolve: make the "pulling obsolescence marker" message important
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1037
diff changeset
    75
  pull obsolescence markers
2059
ebbce3be9142 pull: also issue warning for old mercurial version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2057
diff changeset
    76
  the remote repository use years old versions of Mercurial and evolve
ebbce3be9142 pull: also issue warning for old mercurial version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2057
diff changeset
    77
  pulling obsmarker using legacy method
ebbce3be9142 pull: also issue warning for old mercurial version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2057
diff changeset
    78
  (please upgrade your server)
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    79
  (run 'hg update' to get a working copy)
1087
82873af0cf10 test-simple4server: add error output for http
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1042
diff changeset
    80
  $ cat ../errors.log
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    81
  $ hg push -R ../other
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    82
  pushing to http://localhost:$HGPORT/
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    83
  searching for changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    84
  no changes found
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    85
  [1]
1087
82873af0cf10 test-simple4server: add error output for http
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1042
diff changeset
    86
  $ cat ../errors.log
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    87
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    88
Capacity testing
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    89
===================
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    90
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
    91
  $ curl -s http://localhost:$HGPORT/?cmd=hello
2060
cbdb68189432 capabilities: properly sort capabilities after updating them
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2059
diff changeset
    92
  capabilities: _evoext_getbundle_obscommon _evoext_obshash_0 _evoext_obshash_1 _evoext_pullobsmarkers_0 _evoext_pushobsmarkers_0 batch * (glob)
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
    93
  $ curl -s http://localhost:$HGPORT/?cmd=capabilities
2060
cbdb68189432 capabilities: properly sort capabilities after updating them
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2059
diff changeset
    94
  _evoext_getbundle_obscommon _evoext_obshash_0 _evoext_obshash_1 _evoext_pullobsmarkers_0 _evoext_pushobsmarkers_0 batch * (no-eol) (glob)
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    95
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
    96
  $ curl -s "http://localhost:$HGPORT/?cmd=listkeys&namespace=namespaces" | sort
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
    97
  bookmarks	
906
24f59f38a202 test: sort output of listkey command
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 885
diff changeset
    98
  namespaces	
24f59f38a202 test: sort output of listkey command
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 885
diff changeset
    99
  obsolete	
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   100
  phases	
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   101
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   102
Push
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   103
=============
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   104
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   105
  $ echo 'A' > a
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   106
  $ hg amend
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   107
  $ hg push
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   108
  pushing to http://localhost:$HGPORT/
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   109
  searching for changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   110
  remote: adding changesets
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   111
  remote: adding manifests
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   112
  remote: adding file changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   113
  remote: added 1 changesets with 1 changes to 1 files (+1 heads)
2057
4c195eb4d2c5 push: add extra warning about pushing to old server
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2046
diff changeset
   114
  the remote repository use years old versions of Mercurial and evolve
4c195eb4d2c5 push: add extra warning about pushing to old server
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2046
diff changeset
   115
  pushing obsmarker using legacy method
4c195eb4d2c5 push: add extra warning about pushing to old server
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2046
diff changeset
   116
  (please upgrade your server)
3000
bd7e8be29542 branching: merge future 6.7.0 in the stable branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2929
diff changeset
   117
  pushing 2 obsolescence markers (* bytes) (glob)
bd7e8be29542 branching: merge future 6.7.0 in the stable branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2929
diff changeset
   118
  remote: 2 obsolescence markers added
2753
b265900a9650 test: update test output from b47fef6d2365
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2073
diff changeset
   119
  remote: obsoleted 1 changesets
1087
82873af0cf10 test-simple4server: add error output for http
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1042
diff changeset
   120
  $ cat ../errors.log
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   121
  $ hg push
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   122
  pushing to http://localhost:$HGPORT/
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   123
  searching for changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   124
  no changes found
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   125
  [1]
1087
82873af0cf10 test-simple4server: add error output for http
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1042
diff changeset
   126
  $ cat ../errors.log
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   127
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   128
Pull
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   129
=============
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   130
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   131
  $ hg -R ../other pull
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   132
  pulling from http://localhost:$HGPORT/
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   133
  searching for changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   134
  adding changesets
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   135
  adding manifests
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   136
  adding file changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   137
  added 1 changesets with 1 changes to [12] files \(\+1 heads\) (re)
1038
45c4739e85dc evolve: make the "pulling obsolescence marker" message important
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1037
diff changeset
   138
  pull obsolescence markers
2059
ebbce3be9142 pull: also issue warning for old mercurial version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2057
diff changeset
   139
  the remote repository use years old versions of Mercurial and evolve
ebbce3be9142 pull: also issue warning for old mercurial version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2057
diff changeset
   140
  pulling obsmarker using legacy method
ebbce3be9142 pull: also issue warning for old mercurial version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2057
diff changeset
   141
  (please upgrade your server)
3000
bd7e8be29542 branching: merge future 6.7.0 in the stable branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2929
diff changeset
   142
  2 obsolescence markers added
2753
b265900a9650 test: update test output from b47fef6d2365
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2073
diff changeset
   143
  obsoleted 1 changesets
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   144
  (run 'hg heads' to see heads)
1087
82873af0cf10 test-simple4server: add error output for http
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1042
diff changeset
   145
  $ cat ../errors.log
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   146
  $ hg -R ../other pull
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   147
  pulling from http://localhost:$HGPORT/
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   148
  searching for changes
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   149
  no changes found
1087
82873af0cf10 test-simple4server: add error output for http
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1042
diff changeset
   150
  $ cat ../errors.log
881
380aa41a53a5 export: add test for simple4server
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
   151
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   152
  $ cd ..
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   153
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   154
Test disabling obsolete advertisement
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   155
===========================================
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   156
(used by bitbucket to select which repo use evolve)
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   157
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
   158
  $ curl -s "http://localhost:$HGPORT/?cmd=listkeys&namespace=namespaces" | sort
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   159
  bookmarks	
906
24f59f38a202 test: sort output of listkey command
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 885
diff changeset
   160
  namespaces	
24f59f38a202 test: sort output of listkey command
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 885
diff changeset
   161
  obsolete	
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   162
  phases	
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
   163
  $ curl -s http://localhost:$HGPORT/?cmd=hello
2060
cbdb68189432 capabilities: properly sort capabilities after updating them
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2059
diff changeset
   164
  capabilities: _evoext_getbundle_obscommon _evoext_obshash_0 _evoext_obshash_1 _evoext_pullobsmarkers_0 _evoext_pushobsmarkers_0 batch * (glob)
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
   165
  $ curl -s http://localhost:$HGPORT/?cmd=capabilities
2060
cbdb68189432 capabilities: properly sort capabilities after updating them
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2059
diff changeset
   166
  _evoext_getbundle_obscommon _evoext_obshash_0 _evoext_obshash_1 _evoext_pullobsmarkers_0 _evoext_pushobsmarkers_0 batch * (no-eol) (glob)
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   167
2073
1885c7d78bf6 server only: test a more standard method of disabling exchange
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2065
diff changeset
   168
  $ echo '[experimental]' >> server/.hg/hgrc
1885c7d78bf6 server only: test a more standard method of disabling exchange
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2065
diff changeset
   169
  $ echo 'evolution=!' >> server/.hg/hgrc
1522
97b9141cbf72 test: use 'killdaemons.py' from the run-tests directory
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1453
diff changeset
   170
  $ $RUNTESTDIR/killdaemons.py $DAEMON_PIDS
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   171
  $ hg serve -R server -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   172
  $ cat hg.pid >> $DAEMON_PIDS
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   173
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
   174
  $ curl -s "http://localhost:$HGPORT/?cmd=listkeys&namespace=namespaces" | sort
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   175
  bookmarks	
906
24f59f38a202 test: sort output of listkey command
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 885
diff changeset
   176
  namespaces	
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   177
  phases	
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
   178
  $ curl -s http://localhost:$HGPORT/?cmd=hello | grep _evoext_pushobsmarkers_0
1365
8ac1b7bd46ea tests: ignores other core output in capability testing
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1356
diff changeset
   179
  [1]
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
   180
  $ curl -s http://localhost:$HGPORT/?cmd=capabilities | grep _evoext_pushobsmarkers_0
1365
8ac1b7bd46ea tests: ignores other core output in capability testing
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1356
diff changeset
   181
  [1]
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   182
2073
1885c7d78bf6 server only: test a more standard method of disabling exchange
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2065
diff changeset
   183
  $ echo 'evolution=' >> server/.hg/hgrc
1522
97b9141cbf72 test: use 'killdaemons.py' from the run-tests directory
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1453
diff changeset
   184
  $ $RUNTESTDIR/killdaemons.py $DAEMON_PIDS
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   185
  $ hg serve -R server -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   186
  $ cat hg.pid >> $DAEMON_PIDS
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   187
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
   188
  $ curl -s "http://localhost:$HGPORT/?cmd=listkeys&namespace=namespaces" | sort
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   189
  bookmarks	
906
24f59f38a202 test: sort output of listkey command
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 885
diff changeset
   190
  namespaces	
24f59f38a202 test: sort output of listkey command
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 885
diff changeset
   191
  obsolete	
882
48804a8d7472 simple4server: option to advertise obsolescence support
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 881
diff changeset
   192
  phases	
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
   193
  $ curl -s http://localhost:$HGPORT/?cmd=hello
2060
cbdb68189432 capabilities: properly sort capabilities after updating them
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2059
diff changeset
   194
  capabilities: _evoext_getbundle_obscommon _evoext_obshash_0 _evoext_obshash_1 _evoext_pullobsmarkers_0 _evoext_pushobsmarkers_0 batch * (glob)
1768
e036dfc8cfcc tests: use curl instead of wget
Simon Farnsworth <simonfar@fb.com>
parents: 1721
diff changeset
   195
  $ curl -s http://localhost:$HGPORT/?cmd=capabilities
2060
cbdb68189432 capabilities: properly sort capabilities after updating them
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2059
diff changeset
   196
  _evoext_getbundle_obscommon _evoext_obshash_0 _evoext_obshash_1 _evoext_pullobsmarkers_0 _evoext_pushobsmarkers_0 batch * (no-eol) (glob)