test-newbranch
40 lines
| 698 B
| text/plain
|
TextLexer
/ tests / test-newbranch
Matt Mackall
|
r3420 | #!/bin/sh | ||
hg init t | ||||
cd t | ||||
Matt Mackall
|
r3502 | hg branches | ||
Matt Mackall
|
r3420 | |||
echo foo > a | ||||
hg add a | ||||
Alexis S. L. Carvalho
|
r3760 | hg ci -m "initial" -d "1000000 0" | ||
Matt Mackall
|
r3502 | hg branch foo | ||
hg branch | ||||
Alexis S. L. Carvalho
|
r3760 | hg ci -m "add branch name" -d "1000000 0" | ||
Matt Mackall
|
r3502 | hg branch bar | ||
Alexis S. L. Carvalho
|
r3760 | hg ci -m "change branch name" -d "1000000 0" | ||
Matt Mackall
|
r3502 | hg branch "" | ||
Alexis S. L. Carvalho
|
r3760 | hg ci -m "clear branch name" -d "1000000 0" | ||
Matt Mackall
|
r3420 | |||
hg co foo | ||||
Matt Mackall
|
r3502 | hg branch | ||
Matt Mackall
|
r3420 | echo bleah > a | ||
Alexis S. L. Carvalho
|
r3760 | hg ci -m "modify a branch" -d "1000000 0" | ||
Matt Mackall
|
r3420 | |||
hg merge | ||||
Matt Mackall
|
r3502 | hg branch | ||
Alexis S. L. Carvalho
|
r3760 | hg ci -m "merge" -d "1000000 0" | ||
Matt Mackall
|
r3420 | hg log | ||
Matt Mackall
|
r3502 | hg branches | ||
hg branches -q | ||||
Thomas Arendsen Hein
|
r3451 | echo % test for invalid branch cache | ||
hg rollback | ||||
Alexis S. L. Carvalho
|
r3761 | cp .hg/branches.cache .hg/bc-invalid | ||
Alexis S. L. Carvalho
|
r3760 | hg log -r foo | ||
Alexis S. L. Carvalho
|
r3761 | cp .hg/bc-invalid .hg/branches.cache | ||
hg --debug log -r foo | ||||
rm .hg/branches.cache | ||||
echo corrupted > .hg/branches.cache | ||||
hg log -qr foo | ||||
cat .hg/branches.cache | ||||