view tests/test-merge7 @ 7069:852f39691a0a

Eliminate normpath from foldmap calls. Normcase already takes care of upper/lower case and /->\ conversions. What's left for normpath is folding of a/../a sequences but this should be either done consistently on both non-folding and folding code path or not at all, otherwise we are introducing inconsistent behavior between the two that has nothing to do with case folding. Second argument against it - normpath being pure Python function is very slow - as much as 50% of time is spend just inside normpath call on my repository.
author Petr Kodl <petrkodl@gmail.com>
date Tue, 30 Sep 2008 17:23:08 -0400
parents 7c36a4fb05a3
children
line wrap: on
line source

#!/bin/sh

# initial
hg init test-a
cd test-a
cat >test.txt <<"EOF"
1
2
3
EOF
hg add test.txt
hg commit -m "Initial" -d "1000000 0"

# clone
cd ..
hg clone test-a test-b

# change test-a
cd test-a
cat >test.txt <<"EOF"
one
two
three
EOF
hg commit -m "Numbers as words" -d "1000000 0"

# change test-b
cd ../test-b
cat >test.txt <<"EOF"
1
2.5
3
EOF
hg commit -m "2 -> 2.5" -d "1000000 0"

# now pull and merge from test-a
hg pull ../test-a
hg merge
# resolve conflict
cat >test.txt <<"EOF"
one
two-point-five
three
EOF
rm -f *.orig
hg resolve -m test.txt
hg commit -m "Merge 1" -d "1000000 0"

# change test-a again
cd ../test-a
cat >test.txt <<"EOF"
one
two-point-one
three
EOF
hg commit -m "two -> two-point-one" -d "1000000 0"

# pull and merge from test-a again
cd ../test-b
hg pull ../test-a
hg merge --debug

cat test.txt

hg debugindex .hg/store/data/test.txt.i

hg log