tests/test-pull-update.t
author Jun Wu <quark@fb.com>
Wed, 02 Aug 2017 21:01:38 -0700
changeset 34040 85bfd6a0bdbf
parent 32698 1b5c61d38a52
child 34661 eb586ed5d8ce
permissions -rw-r--r--
run-tests: extract prefix of bisect commands to a variable This does not change any logic. Differential Revision: https://phab.mercurial-scm.org/D577
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
12279
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
     1
  $ hg init t
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
     2
  $ cd t
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
     3
  $ echo 1 > foo
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
     4
  $ hg ci -Am m
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
     5
  adding foo
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
     6
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
     7
  $ cd ..
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
     8
  $ hg clone t tt
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
     9
  updating to branch default
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    10
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    11
  $ cd tt
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    12
  $ echo 1.1 > foo
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    13
  $ hg ci -Am m
5080
73fdc8bd3ed8 Update on pull -u when heads were closed (fixes issue666).
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
    14
12279
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    15
  $ cd ../t
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    16
  $ echo 1.2 > foo
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    17
  $ hg ci -Am m
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    18
31167
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    19
Should respect config to disable dirty update
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    20
  $ hg co -qC 0
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    21
  $ echo 2 > foo
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    22
  $ hg --config experimental.updatecheck=abort pull -u ../tt
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    23
  pulling from ../tt
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    24
  searching for changes
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    25
  adding changesets
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    26
  adding manifests
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    27
  adding file changes
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    28
  added 1 changesets with 1 changes to 1 files (+1 heads)
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    29
  abort: uncommitted changes
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    30
  [255]
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    31
  $ hg --config extensions.strip= strip --no-backup tip
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    32
  $ hg co -qC tip
696e321b304d update: add experimental config for default way of handling dirty wdir
Martin von Zweigbergk <martinvonz@google.com>
parents: 30332
diff changeset
    33
28065
6b1fc09c699a update: change default destination to tipmost descendant (issue4673) (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 26968
diff changeset
    34
Should not update to the other topological branch:
5080
73fdc8bd3ed8 Update on pull -u when heads were closed (fixes issue666).
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
    35
12279
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    36
  $ hg pull -u ../tt
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    37
  pulling from ../tt
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    38
  searching for changes
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    39
  adding changesets
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    40
  adding manifests
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    41
  adding file changes
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    42
  added 1 changesets with 1 changes to 1 files (+1 heads)
28065
6b1fc09c699a update: change default destination to tipmost descendant (issue4673) (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 26968
diff changeset
    43
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
32698
1b5c61d38a52 update: show the commit to which we updated in case of multiple heads (BC)
Pulkit Goyal <7895pulkit@gmail.com>
parents: 31167
diff changeset
    44
  updated to "800c91d5bfc1: m"
28065
6b1fc09c699a update: change default destination to tipmost descendant (issue4673) (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 26968
diff changeset
    45
  1 other heads for branch "default"
12279
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    46
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    47
  $ cd ../tt
5080
73fdc8bd3ed8 Update on pull -u when heads were closed (fixes issue666).
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
    48
28065
6b1fc09c699a update: change default destination to tipmost descendant (issue4673) (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 26968
diff changeset
    49
Should not update to the other branch:
12279
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    50
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    51
  $ hg pull -u ../t
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    52
  pulling from ../t
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    53
  searching for changes
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    54
  adding changesets
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    55
  adding manifests
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    56
  adding file changes
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    57
  added 1 changesets with 1 changes to 1 files (+1 heads)
28065
6b1fc09c699a update: change default destination to tipmost descendant (issue4673) (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 26968
diff changeset
    58
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
32698
1b5c61d38a52 update: show the commit to which we updated in case of multiple heads (BC)
Pulkit Goyal <7895pulkit@gmail.com>
parents: 31167
diff changeset
    59
  updated to "107cefe13e42: m"
28065
6b1fc09c699a update: change default destination to tipmost descendant (issue4673) (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 26968
diff changeset
    60
  1 other heads for branch "default"
5080
73fdc8bd3ed8 Update on pull -u when heads were closed (fixes issue666).
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
    61
12279
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    62
  $ HGMERGE=true hg merge
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    63
  merging foo
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    64
  0 files updated, 1 files merged, 0 files removed, 0 files unresolved
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    65
  (branch merge, don't forget to commit)
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    66
  $ hg ci -mm
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    67
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    68
  $ cd ../t
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    69
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    70
Should work:
5080
73fdc8bd3ed8 Update on pull -u when heads were closed (fixes issue666).
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
    71
12279
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    72
  $ hg pull -u ../tt
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    73
  pulling from ../tt
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    74
  searching for changes
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    75
  adding changesets
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    76
  adding manifests
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    77
  adding file changes
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    78
  added 1 changesets with 1 changes to 1 files (-1 heads)
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    79
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
28e2e3804f2e combine tests
Adrian Buehlmann <adrian@cadifra.com>
parents: 5080
diff changeset
    80
28273
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    81
Similarity between "hg update" and "hg pull -u" in handling bookmark
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    82
====================================================================
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    83
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    84
Test that updating activates the bookmark, which matches with the
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    85
explicit destination of the update.
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    86
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    87
  $ echo 4 >> foo
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    88
  $ hg commit -m "#4"
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    89
  $ hg bookmark active-after-pull
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    90
  $ cd ../tt
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    91
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    92
(1) activating by --rev BOOKMARK
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    93
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    94
  $ hg bookmark -f active-before-pull
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    95
  $ hg bookmarks
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    96
   * active-before-pull        3:483b76ad4309
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    97
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    98
  $ hg pull -u -r active-after-pull
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
    99
  pulling from $TESTTMP/t (glob)
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   100
  searching for changes
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   101
  adding changesets
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   102
  adding manifests
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   103
  adding file changes
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   104
  added 1 changesets with 1 changes to 1 files
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   105
  adding remote bookmark active-after-pull
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   106
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   107
  (activating bookmark active-after-pull)
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   108
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   109
  $ hg parents -q
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   110
  4:f815b3da6163
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   111
  $ hg bookmarks
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   112
   * active-after-pull         4:f815b3da6163
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   113
     active-before-pull        3:483b76ad4309
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   114
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   115
(discard pulled changes)
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   116
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   117
  $ hg update -q 483b76ad4309
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   118
  $ hg rollback -q
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   119
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   120
(2) activating by URL#BOOKMARK
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   121
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   122
  $ hg bookmark -f active-before-pull
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   123
  $ hg bookmarks
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   124
   * active-before-pull        3:483b76ad4309
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   125
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   126
  $ hg pull -u $TESTTMP/t#active-after-pull
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   127
  pulling from $TESTTMP/t (glob)
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   128
  searching for changes
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   129
  adding changesets
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   130
  adding manifests
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   131
  adding file changes
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   132
  added 1 changesets with 1 changes to 1 files
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   133
  adding remote bookmark active-after-pull
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   134
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   135
  (activating bookmark active-after-pull)
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   136
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   137
  $ hg parents -q
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   138
  4:f815b3da6163
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   139
  $ hg bookmarks
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   140
   * active-after-pull         4:f815b3da6163
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   141
     active-before-pull        3:483b76ad4309
9ac8955d8c45 pull: activate a bookmark matching with the destination of the update (BC)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28065
diff changeset
   142
28274
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   143
(discard pulled changes)
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   144
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   145
  $ hg update -q 483b76ad4309
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   146
  $ hg rollback -q
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   147
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   148
Test that updating deactivates current active bookmark, if the
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   149
destination of the update is explicitly specified, and it doesn't
30332
318a24b52eeb spelling: fixes of non-dictionary words
Mads Kiilerich <madski@unity3d.com>
parents: 28274
diff changeset
   150
match with the name of any existing bookmarks.
28274
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   151
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   152
  $ cd ../t
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   153
  $ hg bookmark -d active-after-pull
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   154
  $ hg branch bar -q
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   155
  $ hg commit -m "#5 (bar #1)"
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   156
  $ cd ../tt
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   157
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   158
(1) deactivating by --rev REV
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   159
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   160
  $ hg bookmark -f active-before-pull
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   161
  $ hg bookmarks
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   162
   * active-before-pull        3:483b76ad4309
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   163
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   164
  $ hg pull -u -r b5e4babfaaa7
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   165
  pulling from $TESTTMP/t (glob)
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   166
  searching for changes
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   167
  adding changesets
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   168
  adding manifests
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   169
  adding file changes
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   170
  added 2 changesets with 1 changes to 1 files
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   171
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   172
  (leaving bookmark active-before-pull)
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   173
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   174
  $ hg parents -q
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   175
  5:b5e4babfaaa7
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   176
  $ hg bookmarks
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   177
     active-before-pull        3:483b76ad4309
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   178
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   179
(discard pulled changes)
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   180
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   181
  $ hg update -q 483b76ad4309
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   182
  $ hg rollback -q
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   183
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   184
(2) deactivating by --branch BRANCH
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   185
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   186
  $ hg bookmark -f active-before-pull
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   187
  $ hg bookmarks
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   188
   * active-before-pull        3:483b76ad4309
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   189
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   190
  $ hg pull -u -b bar
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   191
  pulling from $TESTTMP/t (glob)
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   192
  searching for changes
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   193
  adding changesets
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   194
  adding manifests
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   195
  adding file changes
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   196
  added 2 changesets with 1 changes to 1 files
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   197
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   198
  (leaving bookmark active-before-pull)
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   199
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   200
  $ hg parents -q
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   201
  5:b5e4babfaaa7
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   202
  $ hg bookmarks
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   203
     active-before-pull        3:483b76ad4309
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   204
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   205
(discard pulled changes)
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   206
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   207
  $ hg update -q 483b76ad4309
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   208
  $ hg rollback -q
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   209
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   210
(3) deactivating by URL#ANOTHER-BRANCH
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   211
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   212
  $ hg bookmark -f active-before-pull
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   213
  $ hg bookmarks
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   214
   * active-before-pull        3:483b76ad4309
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   215
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   216
  $ hg pull -u $TESTTMP/t#bar
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   217
  pulling from $TESTTMP/t (glob)
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   218
  searching for changes
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   219
  adding changesets
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   220
  adding manifests
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   221
  adding file changes
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   222
  added 2 changesets with 1 changes to 1 files
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   223
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   224
  (leaving bookmark active-before-pull)
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   225
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   226
  $ hg parents -q
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   227
  5:b5e4babfaaa7
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   228
  $ hg bookmarks
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   229
     active-before-pull        3:483b76ad4309
5d9578d9ad1a pull: deactivate a bookmark not matching with the destination of the update
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 28273
diff changeset
   230
16913
f2719b387380 tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents: 14485
diff changeset
   231
  $ cd ..