tests/test-empty-group.t
author Matt Harbison <matt_harbison@yahoo.com>
Sun, 12 Nov 2017 00:24:38 -0500
branchstable
changeset 35167 9fb2b0b41bec
parent 34661 eb586ed5d8ce
permissions -rw-r--r--
test-largefiles: demonstrate problems with renaming and reverting a directory These things were uncovered looking at issue5738. First, if the destination directory exists under .hglf, the source is moved under the destination instead of renaming the last component for `hg mv srcdir dstdir`. This is extra confusing, because it occurs even if the user visible destination (i.e. the path _not_ under .hglf) does not exist. Additionally, when a largefile is forgotten via revert, any modifications end up getting clobbered. For normal files, the forgotten file is left unchanged, as shown by test-import.t. The forget command on a largefile will correctly leave the file unmodified.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
4659
7a7d4937272b Kill trailing spaces
Thomas Arendsen Hein <thomas@intevation.de>
parents: 3853
diff changeset
     1
#  A          B
7a7d4937272b Kill trailing spaces
Thomas Arendsen Hein <thomas@intevation.de>
parents: 3853
diff changeset
     2
#
7a7d4937272b Kill trailing spaces
Thomas Arendsen Hein <thomas@intevation.de>
parents: 3853
diff changeset
     3
#  3  4       3
7a7d4937272b Kill trailing spaces
Thomas Arendsen Hein <thomas@intevation.de>
parents: 3853
diff changeset
     4
#  |\/|       |\
7a7d4937272b Kill trailing spaces
Thomas Arendsen Hein <thomas@intevation.de>
parents: 3853
diff changeset
     5
#  |/\|       | \
7a7d4937272b Kill trailing spaces
Thomas Arendsen Hein <thomas@intevation.de>
parents: 3853
diff changeset
     6
#  1  2       1  2
7a7d4937272b Kill trailing spaces
Thomas Arendsen Hein <thomas@intevation.de>
parents: 3853
diff changeset
     7
#  \ /        \ /
2339
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
     8
#   0          0
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
     9
#
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
    10
# if the result of the merge of 1 and 2
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
    11
# is the same in 3 and 4, no new manifest
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
    12
# will be created and the manifest group
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
    13
# will be empty during the pull
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
    14
#
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
    15
# (plus we test a failure where outgoing
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
    16
# wrongly reported the number of csets)
11422943cf72 document and fix findincoming
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
diff changeset
    17
12189
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    18
  $ hg init a
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    19
  $ cd a
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    20
  $ touch init
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    21
  $ hg ci -A -m 0
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    22
  adding init
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    23
  $ touch x y
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    24
  $ hg ci -A -m 1
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    25
  adding x
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    26
  adding y
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    27
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    28
  $ hg update 0
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    29
  0 files updated, 0 files merged, 2 files removed, 0 files unresolved
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    30
  $ touch x y
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    31
  $ hg ci -A -m 2
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    32
  adding x
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    33
  adding y
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    34
  created new head
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    35
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    36
  $ hg merge 1
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    37
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    38
  (branch merge, don't forget to commit)
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    39
  $ hg ci -A -m m1
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    40
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    41
  $ hg update -C 1
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    42
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    43
  $ hg merge 2
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    44
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    45
  (branch merge, don't forget to commit)
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    46
  $ hg ci -A -m m2
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    47
  created new head
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    48
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    49
  $ cd ..
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    50
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    51
  $ hg clone -r 3 a b
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    52
  adding changesets
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    53
  adding manifests
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    54
  adding file changes
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    55
  added 4 changesets with 3 changes to 3 files
34661
eb586ed5d8ce transaction-summary: show the range of new revisions upon pull/unbundle (BC)
Denis Laxalde <denis.laxalde@logilab.fr>
parents: 14162
diff changeset
    56
  new changesets 5fcb73622933:d15a0c284984
12189
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    57
  updating to branch default
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    58
  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    59
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    60
  $ hg clone -r 4 a c
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>
parents: 12156
diff changeset
    61
  adding changesets
fb0c6373ec36 tests: unify test-empty-group
Adrian Buehlmann <adrian@cadifra.com>