tests/test-clone-update-order.t
author Adrian Buehlmann <adrian@cadifra.com>
Tue, 14 Sep 2010 18:43:24 +0200
changeset 12286 63352a7a8c1c
parent 10637 tests/test-clone-update-order@7ce62865d72a
child 12316 4134686b83e1
permissions -rw-r--r--
tests: unify test-clone-update-order
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
     1
  $ hg init
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
     2
  $ echo foo > bar
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
     3
  $ hg commit -Am default
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
     4
  adding bar
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
     5
  $ hg up -r null
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
     6
  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
     7
  $ hg branch mine
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
     8
  marked working directory as branch mine
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
     9
  $ echo hello > world
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    10
  $ hg commit -Am hello
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    11
  adding world
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    12
  $ hg up -r null
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    13
  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    14
  $ hg branch other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    15
  marked working directory as branch other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    16
  $ echo good > bye
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    17
  $ hg commit -Am other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    18
  adding bye
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    19
  $ hg up -r mine
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    20
  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    21
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    22
  $ hg clone -U -u . .#other ../b -r 0 -r 1 -r 2 -b other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    23
  abort: cannot specify both --noupdate and --updaterev
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
    24
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    25
  $ hg clone -U .#other ../b -r 0 -r 1 -r 2 -b other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    26
  requesting all changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    27
  adding changesets
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    28
  adding manifests
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    29
  adding file changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    30
  added 3 changesets with 3 changes to 3 files (+2 heads)
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    31
  $ rm -rf ../b
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
    32
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    33
  $ hg clone -u . .#other ../b -r 0 -r 1 -r 2 -b other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    34
  requesting all changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    35
  adding changesets
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    36
  adding manifests
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    37
  adding file changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    38
  added 3 changesets with 3 changes to 3 files (+2 heads)
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    39
  updating to branch mine
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    40
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    41
  $ rm -rf ../b
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
    42
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    43
  $ hg clone -u 0 .#other ../b -r 0 -r 1 -r 2 -b other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    44
  requesting all changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    45
  adding changesets
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    46
  adding manifests
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    47
  adding file changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    48
  added 3 changesets with 3 changes to 3 files (+2 heads)
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    49
  updating to branch default
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    50
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    51
  $ rm -rf ../b
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
    52
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    53
  $ hg clone -u 1 .#other ../b -r 0 -r 1 -r 2 -b other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    54
  requesting all changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    55
  adding changesets
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    56
  adding manifests
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    57
  adding file changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    58
  added 3 changesets with 3 changes to 3 files (+2 heads)
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    59
  updating to branch mine
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    60
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    61
  $ rm -rf ../b
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
    62
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    63
  $ hg clone -u 2 .#other ../b -r 0 -r 1 -r 2 -b other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    64
  requesting all changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    65
  adding changesets
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    66
  adding manifests
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    67
  adding file changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    68
  added 3 changesets with 3 changes to 3 files (+2 heads)
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    69
  updating to branch other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    70
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    71
  $ rm -rf ../b
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
    72
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    73
Test -r mine ... mine is ignored:
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
    74
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    75
  $ hg clone -u 2 .#other ../b -r mine -r 0 -r 1 -r 2 -b other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    76
  requesting all changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    77
  adding changesets
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    78
  adding manifests
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    79
  adding file changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    80
  added 3 changesets with 3 changes to 3 files (+2 heads)
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    81
  updating to branch other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    82
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    83
  $ rm -rf ../b
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
    84
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    85
  $ hg clone .#other ../b -b default -b mine
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    86
  requesting all changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    87
  adding changesets
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    88
  adding manifests
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    89
  adding file changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    90
  added 3 changesets with 3 changes to 3 files (+2 heads)
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    91
  updating to branch default
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    92
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    93
  $ rm -rf ../b
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
    94
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    95
  $ hg clone .#other ../b
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    96
  requesting all changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    97
  adding changesets
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    98
  adding manifests
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
    99
  adding file changes
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   100
  added 1 changesets with 1 changes to 1 files
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   101
  updating to branch other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   102
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   103
  $ rm -rf ../b
10637
7ce62865d72a commands: document and test hg clone update priority
timeless <timeless@gmail.com>
parents:
diff changeset
   104
12286
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   105
  $ hg clone -U . ../c -r 1 -r 2 > /dev/null
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   106
  $ hg clone ../c ../b
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   107
  updating to branch other
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   108
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   109
  $ rm -rf ../b ../c
63352a7a8c1c tests: unify test-clone-update-order
Adrian Buehlmann <adrian@cadifra.com>
parents: 10637
diff changeset
   110