tests/test-copies-in-changeset.t
author Martin von Zweigbergk <martinvonz@google.com>
Fri, 09 Oct 2020 09:17:47 -0700
changeset 45688 ed0ded64a8a9
parent 45634 9a6b409b8ebc
child 45771 f90a5c211251
permissions -rw-r--r--
py3: convert an exception message to bytes One of our users ran into this (unrelated to my recent work on more specific errors). Differential Revision: https://phab.mercurial-scm.org/D9184
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
     1
#testcases extra sidedata
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
     2
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
     3
#if extra
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
     4
  $ cat >> $HGRCPATH << EOF
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
     5
  > [experimental]
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
     6
  > copies.write-to=changeset-only
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
     7
  > copies.read-from=changeset-only
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
     8
  > [alias]
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
     9
  > changesetcopies = log -r . -T 'files: {files}
42406
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
    10
  >   {extras % "{ifcontains("files", key, "{key}: {value}\n")}"}
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    11
  >   {extras % "{ifcontains("copies", key, "{key}: {value}\n")}"}'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    12
  > EOF
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    13
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    14
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    15
#if sidedata
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    16
  $ cat >> $HGRCPATH << EOF
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    17
  > [format]
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    18
  > exp-use-copies-side-data-changeset = yes
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    19
  > EOF
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    20
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    21
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    22
  $ cat >> $HGRCPATH << EOF
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    23
  > [alias]
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    24
  > showcopies = log -r . -T '{file_copies % "{source} -> {name}\n"}'
42289
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
    25
  > [extensions]
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
    26
  > rebase =
42858
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
    27
  > split =
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    28
  > EOF
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    29
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    30
Check that copies are recorded correctly
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    31
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    32
  $ hg init repo
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    33
  $ cd repo
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    34
#if sidedata
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    35
  $ hg debugformat -v
44799
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    36
  format-variant     repo config default
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    37
  fncache:            yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    38
  dotencode:          yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    39
  generaldelta:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    40
  sparserevlog:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    41
  sidedata:           yes    yes      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    42
  persistent-nodemap:  no     no      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    43
  copies-sdc:         yes    yes      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    44
  plain-cl-delta:     yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    45
  compression:        zlib   zlib    zlib
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    46
  compression-level:  default default default
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    47
#else
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    48
  $ hg debugformat -v
44799
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    49
  format-variant     repo config default
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    50
  fncache:            yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    51
  dotencode:          yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    52
  generaldelta:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    53
  sparserevlog:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    54
  sidedata:            no     no      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    55
  persistent-nodemap:  no     no      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    56
  copies-sdc:          no     no      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    57
  plain-cl-delta:     yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    58
  compression:        zlib   zlib    zlib
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
    59
  compression-level:  default default default
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    60
#endif
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    61
  $ echo a > a
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    62
  $ hg add a
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    63
  $ hg ci -m initial
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    64
  $ hg cp a b
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    65
  $ hg cp a c
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    66
  $ hg cp a d
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    67
  $ hg ci -m 'copy a to b, c, and d'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    68
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    69
#if extra
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    70
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    71
  $ hg changesetcopies
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    72
  files: b c d
42427
027f1567f97f copies: separate added/removed files by newline instead of null
Martin von Zweigbergk <martinvonz@google.com>
parents: 42426
diff changeset
    73
  filesadded: 0
027f1567f97f copies: separate added/removed files by newline instead of null
Martin von Zweigbergk <martinvonz@google.com>
parents: 42426
diff changeset
    74
  1
027f1567f97f copies: separate added/removed files by newline instead of null
Martin von Zweigbergk <martinvonz@google.com>
parents: 42426
diff changeset
    75
  2
42406
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
    76
  
42426
a1f87294471f copies: also encode p[12]copies destination as index into "files" list
Martin von Zweigbergk <martinvonz@google.com>
parents: 42406
diff changeset
    77
  p1copies: 0\x00a (esc)
a1f87294471f copies: also encode p[12]copies destination as index into "files" list
Martin von Zweigbergk <martinvonz@google.com>
parents: 42406
diff changeset
    78
  1\x00a (esc)
a1f87294471f copies: also encode p[12]copies destination as index into "files" list
Martin von Zweigbergk <martinvonz@google.com>
parents: 42406
diff changeset
    79
  2\x00a (esc)
43142
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
    80
#else
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
    81
  $ hg debugsidedata -c -v -- -1
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
    82
  1 sidedata entries
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
    83
   entry-0014 size 44
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
    84
    '\x00\x00\x00\x04\x00\x00\x00\x00\x01\x00\x00\x00\x00\x06\x00\x00\x00\x02\x00\x00\x00\x00\x06\x00\x00\x00\x03\x00\x00\x00\x00\x06\x00\x00\x00\x04\x00\x00\x00\x00abcd'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    85
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    86
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    87
  $ hg showcopies
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    88
  a -> b
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    89
  a -> c
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    90
  a -> d
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    91
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    92
#if extra
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
    93
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    94
  $ hg showcopies --config experimental.copies.read-from=compatibility
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    95
  a -> b
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    96
  a -> c
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    97
  a -> d
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
    98
  $ hg showcopies --config experimental.copies.read-from=filelog-only
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
    99
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   100
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   101
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   102
Check that renames are recorded correctly
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   103
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   104
  $ hg mv b b2
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   105
  $ hg ci -m 'rename b to b2'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   106
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   107
#if extra
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   108
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   109
  $ hg changesetcopies
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   110
  files: b b2
42406
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   111
  filesadded: 1
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   112
  filesremoved: 0
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   113
  
42426
a1f87294471f copies: also encode p[12]copies destination as index into "files" list
Martin von Zweigbergk <martinvonz@google.com>
parents: 42406
diff changeset
   114
  p1copies: 1\x00b (esc)
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   115
43142
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   116
#else
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   117
  $ hg debugsidedata -c -v -- -1
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   118
  1 sidedata entries
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   119
   entry-0014 size 25
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   120
    '\x00\x00\x00\x02\x0c\x00\x00\x00\x01\x00\x00\x00\x00\x06\x00\x00\x00\x03\x00\x00\x00\x00bb2'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   121
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   122
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   123
  $ hg showcopies
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   124
  b -> b2
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   125
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   126
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   127
Rename onto existing file. This should get recorded in the changeset files list and in the extras,
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   128
even though there is no filelog entry.
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   129
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   130
  $ hg cp b2 c --force
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   131
  $ hg st --copies
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   132
  M c
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   133
    b2
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   134
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   135
#if extra
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   136
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   137
  $ hg debugindex c
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   138
     rev linkrev nodeid       p1           p2
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   139
       0       1 b789fdd96dc2 000000000000 000000000000
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   140
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   141
#else
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   142
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   143
  $ hg debugindex c
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   144
     rev linkrev nodeid       p1           p2
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   145
       0       1 37d9b5d994ea 000000000000 000000000000
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   146
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   147
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   148
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   149
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   150
  $ hg ci -m 'move b onto d'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   151
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   152
#if extra
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   153
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   154
  $ hg changesetcopies
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   155
  files: c
42406
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   156
  
42426
a1f87294471f copies: also encode p[12]copies destination as index into "files" list
Martin von Zweigbergk <martinvonz@google.com>
parents: 42406
diff changeset
   157
  p1copies: 0\x00b2 (esc)
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   158
43142
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   159
#else
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   160
  $ hg debugsidedata -c -v -- -1
43231
30570a056fa8 sidedatacopies: only store an entry if it has values
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43167
diff changeset
   161
  1 sidedata entries
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   162
   entry-0014 size 25
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   163
    '\x00\x00\x00\x02\x00\x00\x00\x00\x02\x00\x00\x00\x00\x16\x00\x00\x00\x03\x00\x00\x00\x00b2c'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   164
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   165
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   166
  $ hg showcopies
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   167
  b2 -> c
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   168
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   169
#if extra
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   170
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   171
  $ hg debugindex c
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   172
     rev linkrev nodeid       p1           p2
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   173
       0       1 b789fdd96dc2 000000000000 000000000000
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   174
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   175
#else
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   176
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   177
  $ hg debugindex c
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   178
     rev linkrev nodeid       p1           p2
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   179
       0       1 37d9b5d994ea 000000000000 000000000000
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   180
       1       3 029625640347 000000000000 000000000000
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   181
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   182
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   183
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   184
Create a merge commit with copying done during merge.
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   185
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   186
  $ hg co 0
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   187
  0 files updated, 0 files merged, 3 files removed, 0 files unresolved
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   188
  $ hg cp a e
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   189
  $ hg cp a f
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   190
  $ hg ci -m 'copy a to e and f'
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   191
  created new head
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   192
  $ hg merge 3
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   193
  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   194
  (branch merge, don't forget to commit)
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   195
File 'a' exists on both sides, so 'g' could be recorded as being from p1 or p2, but we currently
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   196
always record it as being from p1
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   197
  $ hg cp a g
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   198
File 'd' exists only in p2, so 'h' should be from p2
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   199
  $ hg cp d h
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   200
File 'f' exists only in p1, so 'i' should be from p1
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   201
  $ hg cp f i
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   202
  $ hg ci -m 'merge'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   203
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   204
#if extra
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   205
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   206
  $ hg changesetcopies
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   207
  files: g h i
42427
027f1567f97f copies: separate added/removed files by newline instead of null
Martin von Zweigbergk <martinvonz@google.com>
parents: 42426
diff changeset
   208
  filesadded: 0
027f1567f97f copies: separate added/removed files by newline instead of null
Martin von Zweigbergk <martinvonz@google.com>
parents: 42426
diff changeset
   209
  1
027f1567f97f copies: separate added/removed files by newline instead of null
Martin von Zweigbergk <martinvonz@google.com>
parents: 42426
diff changeset
   210
  2
42406
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   211
  
42426
a1f87294471f copies: also encode p[12]copies destination as index into "files" list
Martin von Zweigbergk <martinvonz@google.com>
parents: 42406
diff changeset
   212
  p1copies: 0\x00a (esc)
a1f87294471f copies: also encode p[12]copies destination as index into "files" list
Martin von Zweigbergk <martinvonz@google.com>
parents: 42406
diff changeset
   213
  2\x00f (esc)
a1f87294471f copies: also encode p[12]copies destination as index into "files" list
Martin von Zweigbergk <martinvonz@google.com>
parents: 42406
diff changeset
   214
  p2copies: 1\x00d (esc)
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   215
43142
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   216
#else
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   217
  $ hg debugsidedata -c -v -- -1
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   218
  1 sidedata entries
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   219
   entry-0014 size 64
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   220
    '\x00\x00\x00\x06\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x00\x00\x00\x00\x00\x00\x00\x03\x00\x00\x00\x00\x06\x00\x00\x00\x04\x00\x00\x00\x00\x07\x00\x00\x00\x05\x00\x00\x00\x01\x06\x00\x00\x00\x06\x00\x00\x00\x02adfghi'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   221
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   222
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   223
  $ hg showcopies
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   224
  a -> g
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   225
  d -> h
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   226
  f -> i
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   227
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   228
Test writing to both changeset and filelog
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   229
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   230
  $ hg cp a j
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   231
#if extra
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   232
  $ hg ci -m 'copy a to j' --config experimental.copies.write-to=compatibility
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   233
  $ hg changesetcopies
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   234
  files: j
42406
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   235
  filesadded: 0
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   236
  filesremoved: 
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   237
  
42426
a1f87294471f copies: also encode p[12]copies destination as index into "files" list
Martin von Zweigbergk <martinvonz@google.com>
parents: 42406
diff changeset
   238
  p1copies: 0\x00a (esc)
42300
278dcb24e535 copies: write empty entries in changeset when also writing to filelog
Martin von Zweigbergk <martinvonz@google.com>
parents: 42291
diff changeset
   239
  p2copies: 
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   240
#else
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   241
  $ hg ci -m 'copy a to j'
43142
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   242
  $ hg debugsidedata -c -v -- -1
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   243
  1 sidedata entries
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   244
   entry-0014 size 24
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   245
    '\x00\x00\x00\x02\x00\x00\x00\x00\x01\x00\x00\x00\x00\x06\x00\x00\x00\x02\x00\x00\x00\x00aj'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   246
#endif
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   247
  $ hg debugdata j 0
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   248
  \x01 (esc)
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   249
  copy: a
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   250
  copyrev: b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   251
  \x01 (esc)
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   252
  a
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   253
  $ hg showcopies
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   254
  a -> j
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   255
  $ hg showcopies --config experimental.copies.read-from=compatibility
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   256
  a -> j
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   257
  $ hg showcopies --config experimental.copies.read-from=filelog-only
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   258
  a -> j
42860
6f0273558c4b tests: show invalid copies when turning off copies-in-changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42859
diff changeset
   259
Existing copy information in the changeset gets removed on amend and writing
6f0273558c4b tests: show invalid copies when turning off copies-in-changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42859
diff changeset
   260
copy information on to the filelog
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   261
#if extra
42860
6f0273558c4b tests: show invalid copies when turning off copies-in-changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42859
diff changeset
   262
  $ hg ci --amend -m 'copy a to j, v2' \
6f0273558c4b tests: show invalid copies when turning off copies-in-changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42859
diff changeset
   263
  > --config experimental.copies.write-to=filelog-only
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   264
  saved backup bundle to $TESTTMP/repo/.hg/strip-backup/*-*-amend.hg (glob)
42860
6f0273558c4b tests: show invalid copies when turning off copies-in-changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42859
diff changeset
   265
  $ hg changesetcopies
6f0273558c4b tests: show invalid copies when turning off copies-in-changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42859
diff changeset
   266
  files: j
6f0273558c4b tests: show invalid copies when turning off copies-in-changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42859
diff changeset
   267
  
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   268
#else
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   269
  $ hg ci --amend -m 'copy a to j, v2'
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   270
  saved backup bundle to $TESTTMP/repo/.hg/strip-backup/*-*-amend.hg (glob)
43142
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   271
  $ hg debugsidedata -c -v -- -1
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   272
  1 sidedata entries
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   273
   entry-0014 size 24
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   274
    '\x00\x00\x00\x02\x00\x00\x00\x00\x01\x00\x00\x00\x00\x06\x00\x00\x00\x02\x00\x00\x00\x00aj'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   275
#endif
42860
6f0273558c4b tests: show invalid copies when turning off copies-in-changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42859
diff changeset
   276
  $ hg showcopies --config experimental.copies.read-from=filelog-only
6f0273558c4b tests: show invalid copies when turning off copies-in-changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42859
diff changeset
   277
  a -> j
42300
278dcb24e535 copies: write empty entries in changeset when also writing to filelog
Martin von Zweigbergk <martinvonz@google.com>
parents: 42291
diff changeset
   278
The entries should be written to extras even if they're empty (so the client
278dcb24e535 copies: write empty entries in changeset when also writing to filelog
Martin von Zweigbergk <martinvonz@google.com>
parents: 42291
diff changeset
   279
won't have to fall back to reading from filelogs)
278dcb24e535 copies: write empty entries in changeset when also writing to filelog
Martin von Zweigbergk <martinvonz@google.com>
parents: 42291
diff changeset
   280
  $ echo x >> j
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   281
#if extra
42300
278dcb24e535 copies: write empty entries in changeset when also writing to filelog
Martin von Zweigbergk <martinvonz@google.com>
parents: 42291
diff changeset
   282
  $ hg ci -m 'modify j' --config experimental.copies.write-to=compatibility
278dcb24e535 copies: write empty entries in changeset when also writing to filelog
Martin von Zweigbergk <martinvonz@google.com>
parents: 42291
diff changeset
   283
  $ hg changesetcopies
278dcb24e535 copies: write empty entries in changeset when also writing to filelog
Martin von Zweigbergk <martinvonz@google.com>
parents: 42291
diff changeset
   284
  files: j
42406
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   285
  filesadded: 
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   286
  filesremoved: 
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   287
  
42300
278dcb24e535 copies: write empty entries in changeset when also writing to filelog
Martin von Zweigbergk <martinvonz@google.com>
parents: 42291
diff changeset
   288
  p1copies: 
278dcb24e535 copies: write empty entries in changeset when also writing to filelog
Martin von Zweigbergk <martinvonz@google.com>
parents: 42291
diff changeset
   289
  p2copies: 
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   290
#else
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   291
  $ hg ci -m 'modify j'
43142
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   292
  $ hg debugsidedata -c -v -- -1
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   293
  1 sidedata entries
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   294
   entry-0014 size 14
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   295
    '\x00\x00\x00\x01\x14\x00\x00\x00\x01\x00\x00\x00\x00j'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   296
#endif
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   297
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   298
Test writing only to filelog
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   299
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   300
  $ hg cp a k
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   301
#if extra
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   302
  $ hg ci -m 'copy a to k' --config experimental.copies.write-to=filelog-only
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   303
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   304
  $ hg changesetcopies
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   305
  files: k
42406
f385ba70e4af changelog: optionally store added and removed files in changeset extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42300
diff changeset
   306
  
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   307
#else
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   308
  $ hg ci -m 'copy a to k'
43142
beed7ce61681 sidedatacopies: write copies information in sidedata when applicable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43141
diff changeset
   309
  $ hg debugsidedata -c -v -- -1
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   310
  1 sidedata entries
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   311
   entry-0014 size 24
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   312
    '\x00\x00\x00\x02\x00\x00\x00\x00\x01\x00\x00\x00\x00\x06\x00\x00\x00\x02\x00\x00\x00\x00ak'
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   313
#endif
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   314
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   315
  $ hg debugdata k 0
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   316
  \x01 (esc)
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   317
  copy: a
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   318
  copyrev: b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   319
  \x01 (esc)
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   320
  a
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   321
#if extra
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   322
  $ hg showcopies
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   323
42142
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   324
  $ hg showcopies --config experimental.copies.read-from=compatibility
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   325
  a -> k
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   326
  $ hg showcopies --config experimental.copies.read-from=filelog-only
5382d8f8530b changelog: parse copy metadata if available in extras
Martin von Zweigbergk <martinvonz@google.com>
parents: 42141
diff changeset
   327
  a -> k
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   328
#else
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   329
  $ hg showcopies
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   330
  a -> k
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   331
#endif
42141
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   332
0e41f40b01cc copies: add config option for writing copy metadata to file and/or changset
Martin von Zweigbergk <martinvonz@google.com>
parents:
diff changeset
   333
  $ cd ..
42289
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   334
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   335
Test rebasing a commit with copy information
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   336
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   337
  $ hg init rebase-rename
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   338
  $ cd rebase-rename
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   339
  $ echo a > a
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   340
  $ hg ci -Aqm 'add a'
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   341
  $ echo a2 > a
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   342
  $ hg ci -m 'modify a'
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   343
  $ hg co -q 0
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   344
  $ hg mv a b
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   345
  $ hg ci -qm 'rename a to b'
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   346
  $ hg rebase -d 1 --config rebase.experimental.inmemory=yes
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   347
  rebasing 2:* "rename a to b" (tip) (glob)
42289
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   348
  merging a and b to b
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   349
  saved backup bundle to $TESTTMP/rebase-rename/.hg/strip-backup/*-*-rebase.hg (glob)
42289
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   350
  $ hg st --change . --copies
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   351
  A b
42291
a13b30555ffb context: reuse changectx._copies() in all but workingctx
Martin von Zweigbergk <martinvonz@google.com>
parents: 42289
diff changeset
   352
    a
42289
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   353
  R a
83b225fbd788 tests: demonstrate loss of changeset copy metadata on rebase
Martin von Zweigbergk <martinvonz@google.com>
parents: 42142
diff changeset
   354
  $ cd ..
42858
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   355
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   356
Test splitting a commit
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   357
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   358
  $ hg init split
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   359
  $ cd split
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   360
  $ echo a > a
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   361
  $ echo b > b
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   362
  $ hg ci -Aqm 'add a and b'
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   363
  $ echo a2 > a
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   364
  $ hg mv b c
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   365
  $ hg ci -m 'modify a, move b to c'
42859
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   366
  $ hg --config ui.interactive=yes split <<EOF
42858
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   367
  > y
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   368
  > y
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   369
  > n
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   370
  > y
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   371
  > EOF
42859
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   372
  diff --git a/a b/a
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   373
  1 hunks, 1 lines changed
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   374
  examine changes to 'a'?
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   375
  (enter ? for help) [Ynesfdaq?] y
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   376
  
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   377
  @@ -1,1 +1,1 @@
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   378
  -a
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   379
  +a2
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   380
  record this change to 'a'?
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   381
  (enter ? for help) [Ynesfdaq?] y
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   382
  
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   383
  diff --git a/b b/c
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   384
  rename from b
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   385
  rename to c
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   386
  examine changes to 'b' and 'c'?
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   387
  (enter ? for help) [Ynesfdaq?] n
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   388
  
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   389
  created new head
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   390
  diff --git a/b b/c
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   391
  rename from b
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   392
  rename to c
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   393
  examine changes to 'b' and 'c'?
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   394
  (enter ? for help) [Ynesfdaq?] y
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   395
  
43141
52781d57313d sidedatacopies: introduce a sidedata testcase for test-copies-in-changeset.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42861
diff changeset
   396
  saved backup bundle to $TESTTMP/split/.hg/strip-backup/*-*-split.hg (glob)
42858
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   397
  $ cd ..
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   398
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   399
Test committing half a rename
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   400
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   401
  $ hg init partial
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   402
  $ cd partial
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   403
  $ echo a > a
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   404
  $ hg ci -Aqm 'add a'
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   405
  $ hg mv a b
42859
2b869a515ba6 context: filter out invalid copies from workingctx.p[12]copies()
Martin von Zweigbergk <martinvonz@google.com>
parents: 42858
diff changeset
   406
  $ hg ci -m 'remove a' a
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   407
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   408
#if sidedata
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   409
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   410
Test upgrading/downgrading to sidedata storage
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   411
==============================================
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   412
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   413
downgrading (keeping some sidedata)
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   414
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   415
  $ hg debugformat -v
44799
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   416
  format-variant     repo config default
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   417
  fncache:            yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   418
  dotencode:          yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   419
  generaldelta:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   420
  sparserevlog:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   421
  sidedata:           yes    yes      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   422
  persistent-nodemap:  no     no      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   423
  copies-sdc:         yes    yes      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   424
  plain-cl-delta:     yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   425
  compression:        zlib   zlib    zlib
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   426
  compression-level:  default default default
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   427
  $ hg debugsidedata -c -- 0
43231
30570a056fa8 sidedatacopies: only store an entry if it has values
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43167
diff changeset
   428
  1 sidedata entries
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   429
   entry-0014 size 14
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   430
  $ hg debugsidedata -c -- 1
43231
30570a056fa8 sidedatacopies: only store an entry if it has values
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43167
diff changeset
   431
  1 sidedata entries
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   432
   entry-0014 size 14
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   433
  $ hg debugsidedata -m -- 0
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   434
  $ cat << EOF > .hg/hgrc
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   435
  > [format]
43167
bca9d1a6c4c5 sidedata: rename the configuration option to `exp-use-side-data`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43148
diff changeset
   436
  > exp-use-side-data = yes
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   437
  > exp-use-copies-side-data-changeset = no
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   438
  > EOF
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   439
  $ hg debugupgraderepo --run --quiet --no-backup > /dev/null
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   440
  $ hg debugformat -v
44799
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   441
  format-variant     repo config default
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   442
  fncache:            yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   443
  dotencode:          yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   444
  generaldelta:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   445
  sparserevlog:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   446
  sidedata:           yes    yes      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   447
  persistent-nodemap:  no     no      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   448
  copies-sdc:          no     no      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   449
  plain-cl-delta:     yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   450
  compression:        zlib   zlib    zlib
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   451
  compression-level:  default default default
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   452
  $ hg debugsidedata -c -- 0
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   453
  1 sidedata entries
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   454
   entry-0014 size 14
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   455
  $ hg debugsidedata -c -- 1
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   456
  1 sidedata entries
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   457
   entry-0014 size 14
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   458
  $ hg debugsidedata -m -- 0
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   459
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   460
upgrading
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   461
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   462
  $ cat << EOF > .hg/hgrc
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   463
  > [format]
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   464
  > exp-use-copies-side-data-changeset = yes
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   465
  > EOF
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   466
  $ hg debugupgraderepo --run --quiet --no-backup > /dev/null
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   467
  $ hg debugformat -v
44799
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   468
  format-variant     repo config default
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   469
  fncache:            yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   470
  dotencode:          yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   471
  generaldelta:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   472
  sparserevlog:       yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   473
  sidedata:           yes    yes      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   474
  persistent-nodemap:  no     no      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   475
  copies-sdc:         yes    yes      no
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   476
  plain-cl-delta:     yes    yes     yes
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   477
  compression:        zlib   zlib    zlib
ea9563e9e65a nodemap: teach `hg debugformat` about the persistent nodemap option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43231
diff changeset
   478
  compression-level:  default default default
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   479
  $ hg debugsidedata -c -- 0
43231
30570a056fa8 sidedatacopies: only store an entry if it has values
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43167
diff changeset
   480
  1 sidedata entries
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   481
   entry-0014 size 14
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   482
  $ hg debugsidedata -c -- 1
43231
30570a056fa8 sidedatacopies: only store an entry if it has values
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43167
diff changeset
   483
  1 sidedata entries
45634
9a6b409b8ebc changing-files: rework the way we store changed files in side-data
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 44799
diff changeset
   484
   entry-0014 size 14
43148
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   485
  $ hg debugsidedata -m -- 0
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   486
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   487
#endif
843da18386d5 sidedatacopies: deal with upgrading and downgrading to that format
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 43142
diff changeset
   488
42858
170b070ec6a5 tests: demonstrate crash when committing subset of copies to changeset
Martin von Zweigbergk <martinvonz@google.com>
parents: 42427
diff changeset
   489
  $ cd ..