comparison tests/test-fetch @ 6206:0b6f12495276

fetch: switch the default parent used for a merge This treats newly pulled changes as authoritative, and local changes as the "satellite" changes. The prior default behaviour is still available, via the --switch-parent option.
author Bryan O'Sullivan <bos@serpentine.com>
date Wed, 05 Mar 2008 09:10:45 -0800
parents 86f5d8f608b7
children 03b13d853dc6
comparison
equal deleted inserted replaced
6205:b193a6e59131 6206:0b6f12495276
22 hg --cwd c commit -d '3 0' -Amc 22 hg --cwd c commit -d '3 0' -Amc
23 23
24 hg clone c d 24 hg clone c d
25 hg clone c e 25 hg clone c e
26 26
27 echo % should merge c into a
27 hg --cwd c fetch -d '4 0' -m 'automated merge' ../a 28 hg --cwd c fetch -d '4 0' -m 'automated merge' ../a
28 ls c 29 ls c
29 30
30 hg --cwd a serve -a localhost -p $HGPORT -d --pid-file=hg.pid 31 hg --cwd a serve -a localhost -p $HGPORT -d --pid-file=hg.pid
31 cat a/hg.pid >> "$DAEMON_PIDS" 32 cat a/hg.pid >> "$DAEMON_PIDS"
35 hg --cwd d tip --template '{desc}\n' 36 hg --cwd d tip --template '{desc}\n'
36 37
37 echo '% fetch over http with auth (should be hidden in desc)' 38 echo '% fetch over http with auth (should be hidden in desc)'
38 hg --cwd e fetch -d '5 0' http://user:password@localhost:$HGPORT/ 39 hg --cwd e fetch -d '5 0' http://user:password@localhost:$HGPORT/
39 hg --cwd e tip --template '{desc}\n' 40 hg --cwd e tip --template '{desc}\n'
41
42 hg clone a f
43 hg clone a g
44
45 echo f > f/f
46 hg --cwd f ci -d '6 0' -Amf
47
48 echo g > g/g
49 hg --cwd g ci -d '6 0' -Amg
50
51 echo % should merge f into g
52 hg --cwd g fetch --switch ../f