annotate tests/test-copytrace-heuristics.t @ 42219:1afd9d1e55ca

tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t This also makes the test cases more consistent since a few had missed the ":" in "changeset:" that the others used. Differential Revision: https://phab.mercurial-scm.org/D6278
author Martin von Zweigbergk <martinvonz@google.com>
date Thu, 18 Apr 2019 22:08:58 -0700
parents a3fd84f4fb38
children 802ae9772ced
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
1 Test for the heuristic copytracing algorithm
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
2 ============================================
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
3
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
4 $ cat >> $TESTTMP/copytrace.sh << '__EOF__'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
5 > initclient() {
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
6 > cat >> $1/.hg/hgrc <<EOF
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
7 > [experimental]
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
8 > copytrace = heuristics
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
9 > copytrace.sourcecommitlimit = -1
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
10 > EOF
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
11 > }
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
12 > __EOF__
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
13 $ . "$TESTTMP/copytrace.sh"
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
14
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
15 $ cat >> $HGRCPATH << EOF
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
16 > [extensions]
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
17 > rebase=
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
18 > shelve=
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
19 > [alias]
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
20 > l = log -G -T 'changeset: {node}\n desc: {desc}\n'
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
21 > pl = log -G -T 'changeset: {node}\n desc: {desc}, phase: {phase}\n'
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
22 > EOF
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
23
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
24 NOTE: calling initclient() set copytrace.sourcecommitlimit=-1 as we want to
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
25 prevent the full copytrace algorithm to run and test the heuristic algorithm
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
26 without complexing the test cases with public and draft commits.
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
27
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
28 Check filename heuristics (same dirname and same basename)
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
29 ----------------------------------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
30
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
31 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
32 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
33 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
34 $ echo a > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
35 $ mkdir dir
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
36 $ echo a > dir/file.txt
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
37 $ hg addremove
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
38 adding a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
39 adding dir/file.txt
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
40 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
41 $ hg mv a b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
42 $ hg mv -q dir dir2
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
43 $ hg ci -m 'mv a b, mv dir/ dir2/'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
44 $ hg up -q 0
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
45 $ echo b > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
46 $ echo b > dir/file.txt
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
47 $ hg ci -qm 'mod a, mod dir/file.txt'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
48
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
49 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
50 @ changeset: 557f403c0afd2a3cf15d7e2fb1f1001a8b85e081
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
51 | desc: mod a, mod dir/file.txt
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
52 | o changeset: 928d74bc9110681920854d845c06959f6dfc9547
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
53 |/ desc: mv a b, mv dir/ dir2/
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
54 o changeset: 3c482b16e54596fed340d05ffaf155f156cda7ee
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
55 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
56
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
57 $ hg rebase -s . -d 1
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
58 rebasing 2:557f403c0afd "mod a, mod dir/file.txt" (tip)
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
59 merging b and a to b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
60 merging dir2/file.txt and dir/file.txt to dir2/file.txt
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
61 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/557f403c0afd-9926eeff-rebase.hg
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
62 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
63 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
64
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
65 Make sure filename heuristics do not when they are not related
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
66 --------------------------------------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
67
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
68 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
69 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
70 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
71 $ echo 'somecontent' > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
72 $ hg add a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
73 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
74 $ hg rm a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
75 $ echo 'completelydifferentcontext' > b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
76 $ hg add b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
77 $ hg ci -m 'rm a, add b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
78 $ hg up -q 0
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
79 $ printf 'somecontent\nmoarcontent' > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
80 $ hg ci -qm 'mode a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
81
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
82 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
83 @ changeset: d526312210b9e8f795d576a77dc643796384d86e
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
84 | desc: mode a
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
85 | o changeset: 46985f76c7e5e5123433527f5c8526806145650b
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
86 |/ desc: rm a, add b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
87 o changeset: e5b71fb099c29d9172ef4a23485aaffd497e4cc0
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
88 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
89
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
90 $ hg rebase -s . -d 1
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
91 rebasing 2:d526312210b9 "mode a" (tip)
39312
a3fd84f4fb38 filemerge: fix the wrong placements of messages in prompt
Pulkit Goyal <pulkit@yandex-team.ru>
parents: 39311
diff changeset
92 file 'a' was deleted in local [dest] but was modified in other [source].
39304
f785073f792c merge: improve interactive one-changed one-deleted message (issue5550)
Augie Fackler <augie@google.com>
parents: 38618
diff changeset
93 What do you want to do?
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
94 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
95 unresolved conflicts (see hg resolve, then hg rebase --continue)
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
96 [1]
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
97
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
98 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
99 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
100
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
101 Test when lca didn't modified the file that was moved
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
102 -----------------------------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
103
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
104 $ hg init repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
105 $ initclient repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
106 $ cd repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
107 $ echo 'somecontent' > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
108 $ hg add a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
109 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
110 $ echo c > c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
111 $ hg add c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
112 $ hg ci -m randomcommit
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
113 $ hg mv a b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
114 $ hg ci -m 'mv a b'
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
115 $ hg up -q 1
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
116 $ echo b > a
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
117 $ hg ci -qm 'mod a'
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
118
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
119 $ hg pl
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
120 @ changeset: 9d5cf99c3d9f8e8b05ba55421f7f56530cfcf3bc
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
121 | desc: mod a, phase: draft
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
122 | o changeset: d760186dd240fc47b91eb9f0b58b0002aaeef95d
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
123 |/ desc: mv a b, phase: draft
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
124 o changeset: 48e1b6ba639d5d7fb313fa7989eebabf99c9eb83
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
125 | desc: randomcommit, phase: draft
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
126 o changeset: e5b71fb099c29d9172ef4a23485aaffd497e4cc0
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
127 desc: initial, phase: draft
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
128
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
129 $ hg rebase -s . -d 2
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
130 rebasing 3:9d5cf99c3d9f "mod a" (tip)
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
131 merging b and a to b
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
132 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/9d5cf99c3d9f-f02358cc-rebase.hg
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
133 $ cd ..
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
134 $ rm -rf repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
135
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
136 Rebase "backwards"
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
137 ------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
138
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
139 $ hg init repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
140 $ initclient repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
141 $ cd repo
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
142 $ echo 'somecontent' > a
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
143 $ hg add a
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
144 $ hg ci -m initial
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
145 $ echo c > c
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
146 $ hg add c
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
147 $ hg ci -m randomcommit
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
148 $ hg mv a b
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
149 $ hg ci -m 'mv a b'
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
150 $ hg up -q 2
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
151 $ echo b > b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
152 $ hg ci -qm 'mod b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
153
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
154 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
155 @ changeset: fbe97126b3969056795c462a67d93faf13e4d298
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
156 | desc: mod b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
157 o changeset: d760186dd240fc47b91eb9f0b58b0002aaeef95d
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
158 | desc: mv a b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
159 o changeset: 48e1b6ba639d5d7fb313fa7989eebabf99c9eb83
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
160 | desc: randomcommit
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
161 o changeset: e5b71fb099c29d9172ef4a23485aaffd497e4cc0
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
162 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
163
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
164 $ hg rebase -s . -d 0
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
165 rebasing 3:fbe97126b396 "mod b" (tip)
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
166 merging a and b to a
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
167 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/fbe97126b396-cf5452a1-rebase.hg
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
168 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
169 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
170
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
171 Check a few potential move candidates
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
172 -------------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
173
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
174 $ hg init repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
175 $ initclient repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
176 $ cd repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
177 $ mkdir dir
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
178 $ echo a > dir/a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
179 $ hg add dir/a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
180 $ hg ci -qm initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
181 $ hg mv dir/a dir/b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
182 $ hg ci -qm 'mv dir/a dir/b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
183 $ mkdir dir2
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
184 $ echo b > dir2/a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
185 $ hg add dir2/a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
186 $ hg ci -qm 'create dir2/a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
187 $ hg up -q 0
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
188 $ echo b > dir/a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
189 $ hg ci -qm 'mod dir/a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
190
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
191 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
192 @ changeset: 6b2f4cece40fd320f41229f23821256ffc08efea
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
193 | desc: mod dir/a
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
194 | o changeset: 4494bf7efd2e0dfdd388e767fb913a8a3731e3fa
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
195 | | desc: create dir2/a
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
196 | o changeset: b1784dfab6ea6bfafeb11c0ac50a2981b0fe6ade
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
197 |/ desc: mv dir/a dir/b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
198 o changeset: 36859b8907c513a3a87ae34ba5b1e7eea8c20944
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
199 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
200
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
201 $ hg rebase -s . -d 2
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
202 rebasing 3:6b2f4cece40f "mod dir/a" (tip)
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
203 merging dir/b and dir/a to dir/b
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
204 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/6b2f4cece40f-503efe60-rebase.hg
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
205 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
206 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
207
34846
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
208 Test the copytrace.movecandidateslimit with many move candidates
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
209 ----------------------------------------------------------------
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
210
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
211 $ hg init repo
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
212 $ initclient repo
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
213 $ cd repo
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
214 $ echo a > a
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
215 $ hg add a
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
216 $ hg ci -m initial
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
217 $ hg mv a foo
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
218 $ echo a > b
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
219 $ echo a > c
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
220 $ echo a > d
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
221 $ echo a > e
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
222 $ echo a > f
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
223 $ echo a > g
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
224 $ hg add b
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
225 $ hg add c
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
226 $ hg add d
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
227 $ hg add e
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
228 $ hg add f
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
229 $ hg add g
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
230 $ hg ci -m 'mv a foo, add many files'
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
231 $ hg up -q ".^"
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
232 $ echo b > a
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
233 $ hg ci -m 'mod a'
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
234 created new head
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
235
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
236 $ hg l
34846
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
237 @ changeset: ef716627c70bf4ca0bdb623cfb0d6fe5b9acc51e
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
238 | desc: mod a
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
239 | o changeset: 8329d5c6bf479ec5ca59b9864f3f45d07213f5a4
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
240 |/ desc: mv a foo, add many files
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
241 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
242 desc: initial
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
243
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
244 With small limit
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
245
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
246 $ hg rebase -s 2 -d 1 --config experimental.copytrace.movecandidateslimit=0
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
247 rebasing 2:ef716627c70b "mod a" (tip)
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
248 skipping copytracing for 'a', more candidates than the limit: 7
39312
a3fd84f4fb38 filemerge: fix the wrong placements of messages in prompt
Pulkit Goyal <pulkit@yandex-team.ru>
parents: 39311
diff changeset
249 file 'a' was deleted in local [dest] but was modified in other [source].
39304
f785073f792c merge: improve interactive one-changed one-deleted message (issue5550)
Augie Fackler <augie@google.com>
parents: 38618
diff changeset
250 What do you want to do?
34846
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
251 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
252 unresolved conflicts (see hg resolve, then hg rebase --continue)
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
253 [1]
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
254
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
255 $ hg rebase --abort
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
256 rebase aborted
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
257
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
258 With default limit which is 100
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
259
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
260 $ hg rebase -s 2 -d 1
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
261 rebasing 2:ef716627c70b "mod a" (tip)
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
262 merging foo and a to foo
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
263 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/ef716627c70b-24681561-rebase.hg
34846
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
264
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
265 $ cd ..
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
266 $ rm -rf repo
f05a6e015ecc copies: add a config to limit the number of candidates to check in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34567
diff changeset
267
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
268 Move file in one branch and delete it in another
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
269 -----------------------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
270
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
271 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
272 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
273 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
274 $ echo a > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
275 $ hg add a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
276 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
277 $ hg mv a b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
278 $ hg ci -m 'mv a b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
279 $ hg up -q ".^"
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
280 $ hg rm a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
281 $ hg ci -m 'del a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
282 created new head
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
283
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
284 $ hg pl
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
285 @ changeset: 7d61ee3b1e48577891a072024968428ba465c47b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
286 | desc: del a, phase: draft
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
287 | o changeset: 472e38d57782172f6c6abed82a94ca0d998c3a22
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
288 |/ desc: mv a b, phase: draft
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
289 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
290 desc: initial, phase: draft
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
291
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
292 $ hg rebase -s 1 -d 2
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
293 rebasing 1:472e38d57782 "mv a b"
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
294 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/472e38d57782-17d50e29-rebase.hg
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
295 $ hg up -q c492ed3c7e35dcd1dc938053b8adf56e2cfbd062
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
296 $ ls
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
297 b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
298 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
299 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
300
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
301 Move a directory in draft branch
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
302 --------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
303
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
304 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
305 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
306 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
307 $ mkdir dir
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
308 $ echo a > dir/a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
309 $ hg add dir/a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
310 $ hg ci -qm initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
311 $ echo b > dir/a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
312 $ hg ci -qm 'mod dir/a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
313 $ hg up -q ".^"
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
314 $ hg mv -q dir/ dir2
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
315 $ hg ci -qm 'mv dir/ dir2/'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
316
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
317 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
318 @ changeset: a33d80b6e352591dfd82784e1ad6cdd86b25a239
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
319 | desc: mv dir/ dir2/
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
320 | o changeset: 6b2f4cece40fd320f41229f23821256ffc08efea
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
321 |/ desc: mod dir/a
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
322 o changeset: 36859b8907c513a3a87ae34ba5b1e7eea8c20944
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
323 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
324
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
325 $ hg rebase -s . -d 1
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
326 rebasing 2:a33d80b6e352 "mv dir/ dir2/" (tip)
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
327 merging dir/a and dir2/a to dir2/a
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
328 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/a33d80b6e352-fecb9ada-rebase.hg
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
329 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
330 $ rm -rf server
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
331 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
332
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
333 Move file twice and rebase mod on top of moves
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
334 ----------------------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
335
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
336 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
337 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
338 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
339 $ echo a > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
340 $ hg add a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
341 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
342 $ hg mv a b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
343 $ hg ci -m 'mv a b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
344 $ hg mv b c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
345 $ hg ci -m 'mv b c'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
346 $ hg up -q 0
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
347 $ echo c > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
348 $ hg ci -m 'mod a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
349 created new head
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
350
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
351 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
352 @ changeset: d413169422167a3fa5275fc5d71f7dea9f5775f3
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
353 | desc: mod a
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
354 | o changeset: d3efd280421d24f9f229997c19e654761c942a71
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
355 | | desc: mv b c
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
356 | o changeset: 472e38d57782172f6c6abed82a94ca0d998c3a22
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
357 |/ desc: mv a b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
358 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
359 desc: initial
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
360 $ hg rebase -s . -d 2
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
361 rebasing 3:d41316942216 "mod a" (tip)
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
362 merging c and a to c
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
363 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/d41316942216-2b5949bc-rebase.hg
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
364
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
365 $ cd ..
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
366 $ rm -rf repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
367
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
368 Move file twice and rebase moves on top of mods
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
369 -----------------------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
370
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
371 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
372 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
373 $ cd repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
374 $ echo a > a
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
375 $ hg add a
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
376 $ hg ci -m initial
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
377 $ hg mv a b
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
378 $ hg ci -m 'mv a b'
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
379 $ hg mv b c
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
380 $ hg ci -m 'mv b c'
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
381 $ hg up -q 0
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
382 $ echo c > a
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
383 $ hg ci -m 'mod a'
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
384 created new head
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
385 $ hg l
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
386 @ changeset: d413169422167a3fa5275fc5d71f7dea9f5775f3
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
387 | desc: mod a
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
388 | o changeset: d3efd280421d24f9f229997c19e654761c942a71
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
389 | | desc: mv b c
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
390 | o changeset: 472e38d57782172f6c6abed82a94ca0d998c3a22
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
391 |/ desc: mv a b
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
392 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
393 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
394 $ hg rebase -s 1 -d .
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
395 rebasing 1:472e38d57782 "mv a b"
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
396 merging a and b to b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
397 rebasing 2:d3efd280421d "mv b c"
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
398 merging b and c to c
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
399 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/472e38d57782-ab8d3c58-rebase.hg
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
400
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
401 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
402 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
403
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
404 Move one file and add another file in the same folder in one branch, modify file in another branch
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
405 --------------------------------------------------------------------------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
406
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
407 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
408 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
409 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
410 $ echo a > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
411 $ hg add a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
412 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
413 $ hg mv a b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
414 $ hg ci -m 'mv a b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
415 $ echo c > c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
416 $ hg add c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
417 $ hg ci -m 'add c'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
418 $ hg up -q 0
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
419 $ echo b > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
420 $ hg ci -m 'mod a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
421 created new head
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
422
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
423 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
424 @ changeset: ef716627c70bf4ca0bdb623cfb0d6fe5b9acc51e
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
425 | desc: mod a
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
426 | o changeset: b1a6187e79fbce851bb584eadcb0cc4a80290fd9
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
427 | | desc: add c
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
428 | o changeset: 472e38d57782172f6c6abed82a94ca0d998c3a22
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
429 |/ desc: mv a b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
430 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
431 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
432
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
433 $ hg rebase -s . -d 2
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
434 rebasing 3:ef716627c70b "mod a" (tip)
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
435 merging b and a to b
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
436 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/ef716627c70b-24681561-rebase.hg
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
437 $ ls
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
438 b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
439 c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
440 $ cat b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
441 b
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
442 $ rm -rf repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
443
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
444 Merge test
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
445 ----------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
446
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
447 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
448 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
449 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
450 $ echo a > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
451 $ hg add a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
452 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
453 $ echo b > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
454 $ hg ci -m 'modify a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
455 $ hg up -q 0
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
456 $ hg mv a b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
457 $ hg ci -m 'mv a b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
458 created new head
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
459 $ hg up -q 2
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
460
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
461 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
462 @ changeset: 472e38d57782172f6c6abed82a94ca0d998c3a22
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
463 | desc: mv a b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
464 | o changeset: b0357b07f79129a3d08a68621271ca1352ae8a09
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
465 |/ desc: modify a
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
466 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
467 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
468
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
469 $ hg merge 1
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
470 merging b and a to b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
471 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
472 (branch merge, don't forget to commit)
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
473 $ hg ci -m merge
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
474 $ ls
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
475 b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
476 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
477 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
478
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
479 Copy and move file
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
480 ------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
481
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
482 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
483 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
484 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
485 $ echo a > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
486 $ hg add a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
487 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
488 $ hg cp a c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
489 $ hg mv a b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
490 $ hg ci -m 'cp a c, mv a b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
491 $ hg up -q 0
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
492 $ echo b > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
493 $ hg ci -m 'mod a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
494 created new head
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
495
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
496 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
497 @ changeset: ef716627c70bf4ca0bdb623cfb0d6fe5b9acc51e
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
498 | desc: mod a
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
499 | o changeset: 4fc3fd13fbdb89ada6b75bfcef3911a689a0dde8
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
500 |/ desc: cp a c, mv a b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
501 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
502 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
503
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
504 $ hg rebase -s . -d 1
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
505 rebasing 2:ef716627c70b "mod a" (tip)
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
506 merging b and a to b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
507 merging c and a to c
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
508 saved backup bundle to $TESTTMP/repo/repo/.hg/strip-backup/ef716627c70b-24681561-rebase.hg
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
509 $ ls
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
510 b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
511 c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
512 $ cat b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
513 b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
514 $ cat c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
515 b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
516 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
517 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
518
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
519 Do a merge commit with many consequent moves in one branch
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
520 ----------------------------------------------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
521
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
522 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
523 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
524 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
525 $ echo a > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
526 $ hg add a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
527 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
528 $ echo b > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
529 $ hg ci -qm 'mod a'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
530 $ hg up -q ".^"
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
531 $ hg mv a b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
532 $ hg ci -qm 'mv a b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
533 $ hg mv b c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
534 $ hg ci -qm 'mv b c'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
535 $ hg up -q 1
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
536 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
537 o changeset: d3efd280421d24f9f229997c19e654761c942a71
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
538 | desc: mv b c
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
539 o changeset: 472e38d57782172f6c6abed82a94ca0d998c3a22
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
540 | desc: mv a b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
541 | @ changeset: ef716627c70bf4ca0bdb623cfb0d6fe5b9acc51e
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
542 |/ desc: mod a
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
543 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
544 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
545
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
546 $ hg merge 3
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
547 merging a and c to c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
548 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
549 (branch merge, don't forget to commit)
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
550 $ hg ci -qm 'merge'
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
551 $ hg pl
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
552 @ changeset: cd29b0d08c0f39bfed4cde1b40e30f419db0c825
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
553 |\ desc: merge, phase: draft
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
554 | o changeset: d3efd280421d24f9f229997c19e654761c942a71
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
555 | | desc: mv b c, phase: draft
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
556 | o changeset: 472e38d57782172f6c6abed82a94ca0d998c3a22
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
557 | | desc: mv a b, phase: draft
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
558 o | changeset: ef716627c70bf4ca0bdb623cfb0d6fe5b9acc51e
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
559 |/ desc: mod a, phase: draft
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
560 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
561 desc: initial, phase: draft
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
562 $ ls
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
563 c
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
564 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
565 $ rm -rf repo
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
566
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
567 Test shelve/unshelve
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
568 -------------------
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
569
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
570 $ hg init repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
571 $ initclient repo
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
572 $ cd repo
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
573 $ echo a > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
574 $ hg add a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
575 $ hg ci -m initial
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
576 $ echo b > a
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
577 $ hg shelve
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
578 shelved as default
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
579 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
580 $ hg mv a b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
581 $ hg ci -m 'mv a b'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
582
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
583 $ hg l
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
584 @ changeset: 472e38d57782172f6c6abed82a94ca0d998c3a22
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
585 | desc: mv a b
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
586 o changeset: 1451231c87572a7d3f92fc210b4b35711c949a98
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
587 desc: initial
34191
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
588 $ hg unshelve
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
589 unshelving change 'default'
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
590 rebasing shelved changes
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
591 merging b and a to b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
592 $ ls
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
593 b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
594 $ cat b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
595 b
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
596 $ cd ..
036d47d7cf39 copytrace: move fast heuristic copytracing algorithm to core
Pulkit Goyal <7895pulkit@gmail.com>
parents:
diff changeset
597 $ rm -rf repo
34295
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
598
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
599 Test full copytrace ability on draft branch
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
600 -------------------------------------------
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
601
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
602 File directory and base name changed in same move
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
603 $ hg init repo
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
604 $ initclient repo
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
605 $ mkdir repo/dir1
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
606 $ cd repo/dir1
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
607 $ echo a > a
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
608 $ hg add a
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
609 $ hg ci -qm initial
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
610 $ cd ..
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
611 $ hg mv -q dir1 dir2
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
612 $ hg mv dir2/a dir2/b
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
613 $ hg ci -qm 'mv a b; mv dir1 dir2'
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
614 $ hg up -q '.^'
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
615 $ cd dir1
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
616 $ echo b >> a
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
617 $ cd ..
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
618 $ hg ci -qm 'mod a'
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
619
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
620 $ hg pl
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
621 @ changeset: 6207d2d318e710b882e3d5ada2a89770efc42c96
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
622 | desc: mod a, phase: draft
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
623 | o changeset: abffdd4e3dfc04bc375034b970299b2a309a1cce
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
624 |/ desc: mv a b; mv dir1 dir2, phase: draft
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
625 o changeset: 81973cd24b58db2fdf18ce3d64fb2cc3284e9ab3
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
626 desc: initial, phase: draft
34295
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
627
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
628 $ hg rebase -s . -d 1 --config experimental.copytrace.sourcecommitlimit=100
34295
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
629 rebasing 2:6207d2d318e7 "mod a" (tip)
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
630 merging dir2/b and dir1/a to dir2/b
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
631 saved backup bundle to $TESTTMP/repo/repo/.hg/strip-backup/6207d2d318e7-1c9779ad-rebase.hg
34295
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
632 $ cat dir2/b
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
633 a
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
634 b
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
635 $ cd ..
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
636 $ rm -rf repo
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
637
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
638 Move directory in one merge parent, while adding file to original directory
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
639 in other merge parent. File moved on rebase.
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
640
34295
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
641 $ hg init repo
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
642 $ initclient repo
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
643 $ mkdir repo/dir1
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
644 $ cd repo/dir1
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
645 $ echo dummy > dummy
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
646 $ hg add dummy
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
647 $ cd ..
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
648 $ hg ci -qm initial
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
649 $ cd dir1
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
650 $ echo a > a
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
651 $ hg add a
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
652 $ cd ..
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
653 $ hg ci -qm 'hg add dir1/a'
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
654 $ hg up -q '.^'
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
655 $ hg mv -q dir1 dir2
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
656 $ hg ci -qm 'mv dir1 dir2'
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
657
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
658 $ hg pl
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
659 @ changeset: e8919e7df8d036e07b906045eddcd4a42ff1915f
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
660 | desc: mv dir1 dir2, phase: draft
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
661 | o changeset: 7c7c6f339be00f849c3cb2df738ca91db78b32c8
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
662 |/ desc: hg add dir1/a, phase: draft
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
663 o changeset: a235dcce55dcf42034c4e374cb200662d0bb4a13
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
664 desc: initial, phase: draft
34295
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
665
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
666 $ hg rebase -s . -d 1 --config experimental.copytrace.sourcecommitlimit=100
34295
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
667 rebasing 2:e8919e7df8d0 "mv dir1 dir2" (tip)
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
668 saved backup bundle to $TESTTMP/repo/repo/.hg/strip-backup/e8919e7df8d0-f62fab62-rebase.hg
34295
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
669 $ ls dir2
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
670 a
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
671 dummy
fc3b8483c6cb copytrace: use the full copytracing method if only drafts are involved
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34191
diff changeset
672 $ rm -rf repo
34318
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
673
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
674 Testing the sourcecommitlimit config
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
675 -----------------------------------
34318
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
676
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
677 $ hg init repo
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
678 $ initclient repo
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
679 $ cd repo
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
680 $ echo a > a
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
681 $ hg ci -Aqm "added a"
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
682 $ echo "more things" >> a
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
683 $ hg ci -qm "added more things to a"
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
684 $ hg up 0
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
685 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
686 $ echo b > b
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
687 $ hg ci -Aqm "added b"
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
688 $ mkdir foo
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
689 $ hg mv a foo/bar
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
690 $ hg ci -m "Moved a to foo/bar"
42219
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
691 $ hg pl
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
692 @ changeset: b4b0f7880e500b5c364a5f07b4a2b167de7a6fb0
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
693 | desc: Moved a to foo/bar, phase: draft
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
694 o changeset: 5f6d8a4bf34ab274ccc9f631c2536964b8a3666d
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
695 | desc: added b, phase: draft
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
696 | o changeset: 8b6e13696c38e8445a759516474640c2f8dddef6
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
697 |/ desc: added more things to a, phase: draft
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
698 o changeset: 9092f1db7931481f93b37d5c9fbcfc341bcd7318
1afd9d1e55ca tests: defines aliases for `hg log` calls in test-copytrace-heuristics.t
Martin von Zweigbergk <martinvonz@google.com>
parents: 39312
diff changeset
699 desc: added a, phase: draft
34318
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
700
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
701 When the sourcecommitlimit is small and we have more drafts, we use heuristics only
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
702
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
703 $ hg rebase -s 8b6e13696 -d .
34318
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
704 rebasing 1:8b6e13696c38 "added more things to a"
39312
a3fd84f4fb38 filemerge: fix the wrong placements of messages in prompt
Pulkit Goyal <pulkit@yandex-team.ru>
parents: 39311
diff changeset
705 file 'a' was deleted in local [dest] but was modified in other [source].
39304
f785073f792c merge: improve interactive one-changed one-deleted message (issue5550)
Augie Fackler <augie@google.com>
parents: 38618
diff changeset
706 What do you want to do?
34318
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
707 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
708 unresolved conflicts (see hg resolve, then hg rebase --continue)
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
709 [1]
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
710
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
711 But when we have "sourcecommitlimit > (no. of drafts from base to c1)", we do
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
712 fullcopytracing
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
713
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
714 $ hg rebase --abort
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
715 rebase aborted
34567
1b261be2033b tests: optimize test-copytrace-heuristics.t
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34318
diff changeset
716 $ hg rebase -s 8b6e13696 -d . --config experimental.copytrace.sourcecommitlimit=100
34318
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
717 rebasing 1:8b6e13696c38 "added more things to a"
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
718 merging foo/bar and a to foo/bar
35400
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34846
diff changeset
719 saved backup bundle to $TESTTMP/repo/repo/repo/.hg/strip-backup/8b6e13696c38-fc14ac83-rebase.hg
34318
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
720 $ cd ..
1826d695ad58 copytrace: add a a new config to limit the number of drafts in heuristics
Pulkit Goyal <7895pulkit@gmail.com>
parents: 34295
diff changeset
721 $ rm -rf repo