test-obsolete.t
991 lines
| 33.1 KiB
| text/troff
|
Tads3Lexer
/ tests / test-obsolete.t
Pierre-Yves David
|
r17171 | $ cat >> $HGRCPATH << EOF | ||
> [phases] | ||||
> # public changeset are not obsolete | ||||
> publish=false | ||||
Pierre-Yves David
|
r21978 | > [ui] | ||
> logtemplate="{rev}:{node|short} ({phase}) [{tags} {bookmarks}] {desc|firstline}\n" | ||||
Pierre-Yves David
|
r25351 | > [experimental] | ||
> # drop me once bundle2 is the default, | ||||
> # added to get test change early. | ||||
> bundle2-exp = True | ||||
Pierre-Yves David
|
r17171 | > EOF | ||
Pierre-Yves.David@ens-lyon.org
|
r17071 | $ mkcommit() { | ||
> echo "$1" > "$1" | ||||
> hg add "$1" | ||||
> hg ci -m "add $1" | ||||
> } | ||||
$ getid() { | ||||
Matt Harbison
|
r24162 | > hg log -T "{node}\n" --hidden -r "desc('$1')" | ||
Pierre-Yves.David@ens-lyon.org
|
r17071 | > } | ||
Patrick Mezard
|
r17252 | $ cat > debugkeys.py <<EOF | ||
> def reposetup(ui, repo): | ||||
> class debugkeysrepo(repo.__class__): | ||||
> def listkeys(self, namespace): | ||||
> ui.write('listkeys %s\n' % (namespace,)) | ||||
> return super(debugkeysrepo, self).listkeys(namespace) | ||||
> | ||||
> if repo.local(): | ||||
> repo.__class__ = debugkeysrepo | ||||
> EOF | ||||
Pierre-Yves.David@ens-lyon.org
|
r17071 | |||
$ hg init tmpa | ||||
$ cd tmpa | ||||
Pierre-Yves David
|
r17296 | $ mkcommit kill_me | ||
Checking that the feature is properly disabled | ||||
$ hg debugobsolete -d '0 0' `getid kill_me` -u babar | ||||
Durham Goode
|
r22950 | abort: creating obsolete markers is not enabled on this repo | ||
Pierre-Yves David
|
r17296 | [255] | ||
Enabling it | ||||
Durham Goode
|
r22955 | $ cat >> $HGRCPATH << EOF | ||
> [experimental] | ||||
> evolution=createmarkers,exchange | ||||
Pierre-Yves David
|
r17296 | > EOF | ||
Pierre-Yves.David@ens-lyon.org
|
r17071 | |||
Killing a single changeset without replacement | ||||
Patrick Mezard
|
r17292 | $ hg debugobsolete 0 | ||
abort: changeset references must be full hexadecimal node identifiers | ||||
[255] | ||||
$ hg debugobsolete '00' | ||||
abort: changeset references must be full hexadecimal node identifiers | ||||
[255] | ||||
Pierre-Yves.David@ens-lyon.org
|
r17071 | $ hg debugobsolete -d '0 0' `getid kill_me` -u babar | ||
Pierre-Yves.David@ens-lyon.org
|
r17074 | $ hg debugobsolete | ||
Pierre-Yves David
|
r22220 | 97b7c2d76b1845ed3eb988cd612611e72406cef0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'babar'} | ||
Pierre-Yves David
|
r18464 | |||
(test that mercurial is not confused) | ||||
$ hg up null --quiet # having 0 as parent prevents it to be hidden | ||||
$ hg tip | ||||
Pierre-Yves David
|
r21978 | -1:000000000000 (public) [tip ] | ||
Pierre-Yves David
|
r18464 | $ hg up --hidden tip --quiet | ||
Pierre-Yves David
|
r22177 | |||
Killing a single changeset with itself should fail | ||||
(simple local safeguard) | ||||
$ hg debugobsolete `getid kill_me` `getid kill_me` | ||||
abort: bad obsmarker input: in-marker cycle with 97b7c2d76b1845ed3eb988cd612611e72406cef0 | ||||
[255] | ||||
Pierre-Yves.David@ens-lyon.org
|
r17071 | $ cd .. | ||
Killing a single changeset with replacement | ||||
Durham Goode
|
r22948 | (and testing the format option) | ||
Pierre-Yves.David@ens-lyon.org
|
r17071 | |||
$ hg init tmpb | ||||
$ cd tmpb | ||||
$ mkcommit a | ||||
$ mkcommit b | ||||
$ mkcommit original_c | ||||
$ hg up "desc('b')" | ||||
0 files updated, 0 files merged, 1 files removed, 0 files unresolved | ||||
$ mkcommit new_c | ||||
created new head | ||||
Patrick Mezard
|
r17390 | $ hg log -r 'hidden()' --template '{rev}:{node|short} {desc}\n' --hidden | ||
FUJIWARA Katsunori
|
r23094 | $ hg debugobsolete --config format.obsstore-version=0 --flag 12 `getid original_c` `getid new_c` -d '121 120' | ||
Patrick Mezard
|
r17390 | $ hg log -r 'hidden()' --template '{rev}:{node|short} {desc}\n' --hidden | ||
2:245bde4270cd add original_c | ||||
Matt Mackall
|
r21033 | $ hg debugrevlog -cd | ||
Sune Foldager
|
r22311 | # rev p1rev p2rev start end deltastart base p1 p2 rawsize totalsize compression heads chainlen | ||
0 -1 -1 0 59 0 0 0 0 58 58 0 1 0 | ||||
1 0 -1 59 118 59 59 0 0 58 116 0 1 0 | ||||
Siddharth Agarwal
|
r23285 | 2 1 -1 118 193 118 118 59 0 76 192 0 1 0 | ||
3 1 -1 193 260 193 193 59 0 66 258 0 2 0 | ||||
Pierre-Yves.David@ens-lyon.org
|
r17074 | $ hg debugobsolete | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves.David@ens-lyon.org
|
r17071 | |||
Durham Goode
|
r22948 | (check for version number of the obsstore) | ||
$ dd bs=1 count=1 if=.hg/store/obsstore 2>/dev/null | ||||
\x00 (no-eol) (esc) | ||||
Pierre-Yves.David@ens-lyon.org
|
r17071 | do it again (it read the obsstore before adding new changeset) | ||
$ hg up '.^' | ||||
0 files updated, 0 files merged, 1 files removed, 0 files unresolved | ||||
$ mkcommit new_2_c | ||||
created new head | ||||
$ hg debugobsolete -d '1337 0' `getid new_c` `getid new_2_c` | ||||
Pierre-Yves.David@ens-lyon.org
|
r17074 | $ hg debugobsolete | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r22220 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
Pierre-Yves.David@ens-lyon.org
|
r17071 | |||
Register two markers with a missing node | ||||
$ hg up '.^' | ||||
0 files updated, 0 files merged, 1 files removed, 0 files unresolved | ||||
$ mkcommit new_3_c | ||||
created new head | ||||
$ hg debugobsolete -d '1338 0' `getid new_2_c` 1337133713371337133713371337133713371337 | ||||
$ hg debugobsolete -d '1339 0' 1337133713371337133713371337133713371337 `getid new_3_c` | ||||
Pierre-Yves.David@ens-lyon.org
|
r17074 | $ hg debugobsolete | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r22220 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||||
1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||||
Pierre-Yves.David@ens-lyon.org
|
r17075 | |||
Pierre-Yves David
|
r17774 | Refuse pathological nullid successors | ||
$ hg debugobsolete -d '9001 0' 1337133713371337133713371337133713371337 0000000000000000000000000000000000000000 | ||||
transaction abort! | ||||
rollback completed | ||||
abort: bad obsolescence marker detected: invalid successors nullid | ||||
[255] | ||||
Pierre-Yves David
|
r17119 | Check that graphlog detect that a changeset is obsolete: | ||
Martin Geisler
|
r20117 | $ hg log -G | ||
Pierre-Yves David
|
r21978 | @ 5:5601fb93a350 (draft) [tip ] add new_3_c | ||
Pierre-Yves David
|
r17119 | | | ||
Pierre-Yves David
|
r21978 | o 1:7c3bad9141dc (draft) [ ] add b | ||
Pierre-Yves David
|
r17119 | | | ||
Pierre-Yves David
|
r21978 | o 0:1f0dee641bb7 (draft) [ ] add a | ||
Pierre-Yves David
|
r17119 | |||
Pierre-Yves David
|
r18268 | check that heads does not report them | ||
$ hg heads | ||||
Pierre-Yves David
|
r21978 | 5:5601fb93a350 (draft) [tip ] add new_3_c | ||
Pierre-Yves David
|
r18268 | $ hg heads --hidden | ||
Pierre-Yves David
|
r21978 | 5:5601fb93a350 (draft) [tip ] add new_3_c | ||
4:ca819180edb9 (draft) [ ] add new_2_c | ||||
3:cdbce2fbb163 (draft) [ ] add new_c | ||||
2:245bde4270cd (draft) [ ] add original_c | ||||
Pierre-Yves David
|
r18268 | |||
check that summary does not report them | ||||
$ hg init ../sink | ||||
$ echo '[paths]' >> .hg/hgrc | ||||
$ echo 'default=../sink' >> .hg/hgrc | ||||
$ hg summary --remote | ||||
parent: 5:5601fb93a350 tip | ||||
add new_3_c | ||||
branch: default | ||||
commit: (clean) | ||||
update: (current) | ||||
Gilles Moris
|
r25382 | phases: 3 draft | ||
Pierre-Yves David
|
r18268 | remote: 3 outgoing | ||
$ hg summary --remote --hidden | ||||
parent: 5:5601fb93a350 tip | ||||
add new_3_c | ||||
branch: default | ||||
commit: (clean) | ||||
update: 3 new changesets, 4 branch heads (merge) | ||||
Gilles Moris
|
r25382 | phases: 6 draft | ||
Pierre-Yves David
|
r18268 | remote: 3 outgoing | ||
Pierre-Yves David
|
r18423 | check that various commands work well with filtering | ||
$ hg tip | ||||
Pierre-Yves David
|
r21978 | 5:5601fb93a350 (draft) [tip ] add new_3_c | ||
Pierre-Yves David
|
r18423 | $ hg log -r 6 | ||
abort: unknown revision '6'! | ||||
[255] | ||||
$ hg log -r 4 | ||||
Pierre-Yves David
|
r23046 | abort: hidden revision '4'! | ||
(use --hidden to access hidden revisions) | ||||
Pierre-Yves David
|
r18423 | [255] | ||
Yuya Nishihara
|
r23062 | $ hg debugrevspec 'rev(6)' | ||
$ hg debugrevspec 'rev(4)' | ||||
Yuya Nishihara
|
r24204 | $ hg debugrevspec 'null' | ||
-1 | ||||
Pierre-Yves David
|
r18423 | |||
Pierre-Yves David
|
r17119 | Check that public changeset are not accounted as obsolete: | ||
Pierre-Yves David
|
r18267 | $ hg --hidden phase --public 2 | ||
Martin Geisler
|
r20117 | $ hg log -G | ||
Pierre-Yves David
|
r21978 | @ 5:5601fb93a350 (draft) [tip ] add new_3_c | ||
Pierre-Yves David
|
r17119 | | | ||
Pierre-Yves David
|
r21978 | | o 2:245bde4270cd (public) [ ] add original_c | ||
|/ | ||||
o 1:7c3bad9141dc (public) [ ] add b | ||||
Pierre-Yves David
|
r17119 | | | ||
Pierre-Yves David
|
r21978 | o 0:1f0dee641bb7 (public) [ ] add a | ||
Pierre-Yves David
|
r17119 | |||
Pierre-Yves David
|
r17829 | And that bumped changeset are detected | ||
-------------------------------------- | ||||
If we didn't filtered obsolete changesets out, 3 and 4 would show up too. Also | ||||
note that the bumped changeset (5:5601fb93a350) is not a direct successor of | ||||
the public changeset | ||||
$ hg log --hidden -r 'bumped()' | ||||
Pierre-Yves David
|
r21978 | 5:5601fb93a350 (draft) [tip ] add new_3_c | ||
Pierre-Yves David
|
r17829 | |||
Pierre-Yves David
|
r17834 | And that we can't push bumped changeset | ||
Pierre-Yves David
|
r18085 | $ hg push ../tmpa -r 0 --force #(make repo related) | ||
Pierre-Yves David
|
r18015 | pushing to ../tmpa | ||
searching for changes | ||||
Pierre-Yves David
|
r18104 | warning: repository is unrelated | ||
Pierre-Yves David
|
r18015 | adding changesets | ||
adding manifests | ||||
adding file changes | ||||
added 1 changesets with 1 changes to 1 files (+1 heads) | ||||
Pierre-Yves David
|
r17834 | $ hg push ../tmpa | ||
pushing to ../tmpa | ||||
searching for changes | ||||
abort: push includes bumped changeset: 5601fb93a350! | ||||
[255] | ||||
Pierre-Yves David
|
r17831 | Fixing "bumped" situation | ||
We need to create a clone of 5 and add a special marker with a flag | ||||
Laurent Charignon
|
r27385 | $ hg summary | ||
parent: 5:5601fb93a350 tip | ||||
add new_3_c | ||||
branch: default | ||||
commit: (clean) | ||||
update: 1 new changesets, 2 branch heads (merge) | ||||
phases: 1 draft | ||||
Matt Harbison
|
r27722 | bumped: 1 changesets | ||
Pierre-Yves David
|
r17831 | $ hg up '5^' | ||
0 files updated, 0 files merged, 1 files removed, 0 files unresolved | ||||
$ hg revert -ar 5 | ||||
adding new_3_c | ||||
$ hg ci -m 'add n3w_3_c' | ||||
created new head | ||||
$ hg debugobsolete -d '1338 0' --flags 1 `getid new_3_c` `getid n3w_3_c` | ||||
$ hg log -r 'bumped()' | ||||
$ hg log -G | ||||
Pierre-Yves David
|
r21978 | @ 6:6f9641995072 (draft) [tip ] add n3w_3_c | ||
Pierre-Yves David
|
r17831 | | | ||
Pierre-Yves David
|
r21978 | | o 2:245bde4270cd (public) [ ] add original_c | ||
|/ | ||||
o 1:7c3bad9141dc (public) [ ] add b | ||||
Pierre-Yves David
|
r17831 | | | ||
Pierre-Yves David
|
r21978 | o 0:1f0dee641bb7 (public) [ ] add a | ||
Pierre-Yves David
|
r17831 | |||
Yuya Nishihara
|
r24681 | $ cd .. | ||
Revision 0 is hidden | ||||
-------------------- | ||||
$ hg init rev0hidden | ||||
$ cd rev0hidden | ||||
$ mkcommit kill0 | ||||
$ hg up -q null | ||||
$ hg debugobsolete `getid kill0` | ||||
$ mkcommit a | ||||
$ mkcommit b | ||||
Should pick the first visible revision as "repo" node | ||||
$ hg archive ../archive-null | ||||
$ cat ../archive-null/.hg_archival.txt | ||||
repo: 1f0dee641bb7258c56bd60e93edfa2405381c41e | ||||
node: 7c3bad9141dcb46ff89abf5f61856facd56e476c | ||||
branch: default | ||||
latesttag: null | ||||
latesttagdistance: 2 | ||||
changessincelatesttag: 2 | ||||
Pierre-Yves David
|
r17831 | |||
Pierre-Yves.David@ens-lyon.org
|
r17075 | $ cd .. | ||
Exchange Test | ||||
============================ | ||||
Destination repo does not have any data | ||||
--------------------------------------- | ||||
Pierre-Yves David
|
r18493 | Simple incoming test | ||
$ hg init tmpc | ||||
$ cd tmpc | ||||
$ hg incoming ../tmpb | ||||
comparing with ../tmpb | ||||
Pierre-Yves David
|
r21978 | 0:1f0dee641bb7 (public) [ ] add a | ||
1:7c3bad9141dc (public) [ ] add b | ||||
2:245bde4270cd (public) [ ] add original_c | ||||
6:6f9641995072 (draft) [tip ] add n3w_3_c | ||||
Pierre-Yves David
|
r18493 | |||
Pierre-Yves.David@ens-lyon.org
|
r17075 | Try to pull markers | ||
Pierre-Yves David
|
r17206 | (extinct changeset are excluded but marker are pushed) | ||
Pierre-Yves.David@ens-lyon.org
|
r17075 | |||
$ hg pull ../tmpb | ||||
pulling from ../tmpb | ||||
requesting all changes | ||||
adding changesets | ||||
adding manifests | ||||
adding file changes | ||||
Pierre-Yves David
|
r17206 | added 4 changesets with 4 changes to 4 files (+1 heads) | ||
Pierre-Yves David
|
r25351 | 5 new obsolescence markers | ||
Pierre-Yves.David@ens-lyon.org
|
r17075 | (run 'hg heads' to see heads, 'hg merge' to merge) | ||
$ hg debugobsolete | ||||
Pierre-Yves David
|
r25118 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r22220 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r17126 | |||
Rollback//Transaction support | ||||
$ hg debugobsolete -d '1340 0' aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb | ||||
$ hg debugobsolete | ||||
Pierre-Yves David
|
r25118 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r22220 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r22220 | aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb 0 (Thu Jan 01 00:22:20 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r17126 | $ hg rollback -n | ||
Pierre-Yves David
|
r17206 | repository tip rolled back to revision 3 (undo debugobsolete) | ||
Pierre-Yves David
|
r17126 | $ hg rollback | ||
Pierre-Yves David
|
r17206 | repository tip rolled back to revision 3 (undo debugobsolete) | ||
Pierre-Yves David
|
r17126 | $ hg debugobsolete | ||
Pierre-Yves David
|
r25118 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r22220 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
Pierre-Yves.David@ens-lyon.org
|
r17075 | |||
$ cd .. | ||||
Pierre-Yves David
|
r18492 | Try to push markers | ||
Pierre-Yves.David@ens-lyon.org
|
r17075 | |||
$ hg init tmpd | ||||
$ hg -R tmpb push tmpd | ||||
pushing to tmpd | ||||
searching for changes | ||||
adding changesets | ||||
adding manifests | ||||
adding file changes | ||||
Pierre-Yves David
|
r17169 | added 4 changesets with 4 changes to 4 files (+1 heads) | ||
Pierre-Yves David
|
r25351 | 5 new obsolescence markers | ||
Pierre-Yves David
|
r22349 | $ hg -R tmpd debugobsolete | sort | ||
1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r22349 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||||
Pierre-Yves David
|
r22220 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
Pierre-Yves.David@ens-lyon.org
|
r17075 | |||
Patrick Mezard
|
r17252 | Check obsolete keys are exchanged only if source has an obsolete store | ||
$ hg init empty | ||||
$ hg --config extensions.debugkeys=debugkeys.py -R empty push tmpd | ||||
pushing to tmpd | ||||
Pierre-Yves David
|
r22019 | listkeys phases | ||
Pierre-Yves David
|
r22239 | listkeys bookmarks | ||
Patrick Mezard
|
r17252 | no changes found | ||
listkeys phases | ||||
[1] | ||||
Pierre-Yves.David@ens-lyon.org
|
r17249 | clone support | ||
(markers are copied and extinct changesets are included to allow hardlinks) | ||||
$ hg clone tmpb clone-dest | ||||
updating to branch default | ||||
3 files updated, 0 files merged, 0 files removed, 0 files unresolved | ||||
$ hg -R clone-dest log -G --hidden | ||||
Pierre-Yves David
|
r21978 | @ 6:6f9641995072 (draft) [tip ] add n3w_3_c | ||
Pierre-Yves.David@ens-lyon.org
|
r17249 | | | ||
Pierre-Yves David
|
r21978 | | x 5:5601fb93a350 (draft) [ ] add new_3_c | ||
|/ | ||||
| x 4:ca819180edb9 (draft) [ ] add new_2_c | ||||
|/ | ||||
| x 3:cdbce2fbb163 (draft) [ ] add new_c | ||||
|/ | ||||
| o 2:245bde4270cd (public) [ ] add original_c | ||||
|/ | ||||
o 1:7c3bad9141dc (public) [ ] add b | ||||
Pierre-Yves.David@ens-lyon.org
|
r17249 | | | ||
Pierre-Yves David
|
r21978 | o 0:1f0dee641bb7 (public) [ ] add a | ||
Pierre-Yves.David@ens-lyon.org
|
r17249 | |||
$ hg -R clone-dest debugobsolete | ||||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r22220 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||||
1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||||
5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||||
Pierre-Yves.David@ens-lyon.org
|
r17249 | |||
Pierre-Yves.David@ens-lyon.org
|
r17075 | |||
Destination repo have existing data | ||||
--------------------------------------- | ||||
On pull | ||||
$ hg init tmpe | ||||
$ cd tmpe | ||||
Pierre-Yves David
|
r22348 | $ hg debugobsolete -d '1339 0' 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 | ||
Pierre-Yves.David@ens-lyon.org
|
r17075 | $ hg pull ../tmpb | ||
pulling from ../tmpb | ||||
requesting all changes | ||||
adding changesets | ||||
adding manifests | ||||
adding file changes | ||||
Pierre-Yves David
|
r17206 | added 4 changesets with 4 changes to 4 files (+1 heads) | ||
Pierre-Yves David
|
r25351 | 5 new obsolescence markers | ||
Pierre-Yves.David@ens-lyon.org
|
r17075 | (run 'hg heads' to see heads, 'hg merge' to merge) | ||
$ hg debugobsolete | ||||
Pierre-Yves David
|
r22348 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r22220 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
Pierre-Yves.David@ens-lyon.org
|
r17075 | |||
Pierre-Yves David
|
r17171 | |||
Pierre-Yves.David@ens-lyon.org
|
r17075 | On push | ||
$ hg push ../tmpc | ||||
pushing to ../tmpc | ||||
searching for changes | ||||
no changes found | ||||
Pierre-Yves David
|
r25351 | 1 new obsolescence markers | ||
Pierre-Yves.David@ens-lyon.org
|
r17075 | [1] | ||
$ hg -R ../tmpc debugobsolete | ||||
Pierre-Yves David
|
r25118 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r22220 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r22348 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r17171 | |||
detect outgoing obsolete and unstable | ||||
--------------------------------------- | ||||
Pierre-Yves David
|
r17206 | |||
Martin Geisler
|
r20117 | $ hg log -G | ||
Pierre-Yves David
|
r21978 | o 3:6f9641995072 (draft) [tip ] add n3w_3_c | ||
Pierre-Yves David
|
r17171 | | | ||
Pierre-Yves David
|
r21978 | | o 2:245bde4270cd (public) [ ] add original_c | ||
|/ | ||||
o 1:7c3bad9141dc (public) [ ] add b | ||||
Pierre-Yves David
|
r17171 | | | ||
Pierre-Yves David
|
r21978 | o 0:1f0dee641bb7 (public) [ ] add a | ||
Pierre-Yves David
|
r17171 | |||
Pierre-Yves David
|
r17831 | $ hg up 'desc("n3w_3_c")' | ||
Pierre-Yves David
|
r17206 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved | ||
Pierre-Yves David
|
r17171 | $ mkcommit original_d | ||
Pierre-Yves David
|
r17206 | $ mkcommit original_e | ||
Pierre-Yves David
|
r22272 | $ hg debugobsolete --record-parents `getid original_d` -d '0 0' | ||
$ hg debugobsolete | grep `getid original_d` | ||||
94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | ||||
Pierre-Yves David
|
r17206 | $ hg log -r 'obsolete()' | ||
Pierre-Yves David
|
r21978 | 4:94b33453f93b (draft) [ ] add original_d | ||
Laurent Charignon
|
r27385 | $ hg summary | ||
parent: 5:cda648ca50f5 tip | ||||
add original_e | ||||
branch: default | ||||
commit: (clean) | ||||
update: 1 new changesets, 2 branch heads (merge) | ||||
phases: 3 draft | ||||
Matt Harbison
|
r27722 | unstable: 1 changesets | ||
Martin Geisler
|
r20117 | $ hg log -G -r '::unstable()' | ||
Pierre-Yves David
|
r21978 | @ 5:cda648ca50f5 (draft) [tip ] add original_e | ||
| | ||||
x 4:94b33453f93b (draft) [ ] add original_d | ||||
Pierre-Yves David
|
r17206 | | | ||
Pierre-Yves David
|
r21978 | o 3:6f9641995072 (draft) [ ] add n3w_3_c | ||
Pierre-Yves David
|
r17171 | | | ||
Pierre-Yves David
|
r21978 | o 1:7c3bad9141dc (public) [ ] add b | ||
Pierre-Yves David
|
r17171 | | | ||
Pierre-Yves David
|
r21978 | o 0:1f0dee641bb7 (public) [ ] add a | ||
Pierre-Yves David
|
r17171 | |||
Pierre-Yves David
|
r17206 | |||
refuse to push obsolete changeset | ||||
$ hg push ../tmpc/ -r 'desc("original_d")' | ||||
pushing to ../tmpc/ | ||||
searching for changes | ||||
push includes an xxx changeset: yyyyyyyyyy
|
r17833 | abort: push includes obsolete changeset: 94b33453f93b! | ||
Pierre-Yves David
|
r17206 | [255] | ||
refuse to push unstable changeset | ||||
Pierre-Yves David
|
r17172 | $ hg push ../tmpc/ | ||
pushing to ../tmpc/ | ||||
searching for changes | ||||
push includes an xxx changeset: yyyyyyyyyy
|
r17833 | abort: push includes unstable changeset: cda648ca50f5! | ||
Pierre-Yves David
|
r17172 | [255] | ||
Pierre-Yves David
|
r17173 | |||
Test that extinct changeset are properly detected | ||||
$ hg log -r 'extinct()' | ||||
Pierre-Yves David
|
r17206 | |||
Don't try to push extinct changeset | ||||
$ hg init ../tmpf | ||||
$ hg out ../tmpf | ||||
comparing with ../tmpf | ||||
searching for changes | ||||
Pierre-Yves David
|
r21978 | 0:1f0dee641bb7 (public) [ ] add a | ||
1:7c3bad9141dc (public) [ ] add b | ||||
2:245bde4270cd (public) [ ] add original_c | ||||
3:6f9641995072 (draft) [ ] add n3w_3_c | ||||
4:94b33453f93b (draft) [ ] add original_d | ||||
5:cda648ca50f5 (draft) [tip ] add original_e | ||||
Pierre-Yves David
|
r17206 | $ hg push ../tmpf -f # -f because be push unstable too | ||
pushing to ../tmpf | ||||
searching for changes | ||||
adding changesets | ||||
adding manifests | ||||
adding file changes | ||||
added 6 changesets with 6 changes to 6 files (+1 heads) | ||||
Pierre-Yves David
|
r25351 | 7 new obsolescence markers | ||
Pierre-Yves David
|
r17206 | |||
no warning displayed | ||||
$ hg push ../tmpf | ||||
pushing to ../tmpf | ||||
searching for changes | ||||
no changes found | ||||
[1] | ||||
Pierre-Yves David
|
r17214 | |||
Do not warn about new head when the new head is a successors of a remote one | ||||
Martin Geisler
|
r20117 | $ hg log -G | ||
Pierre-Yves David
|
r21978 | @ 5:cda648ca50f5 (draft) [tip ] add original_e | ||
Pierre-Yves David
|
r17214 | | | ||
Pierre-Yves David
|
r21978 | x 4:94b33453f93b (draft) [ ] add original_d | ||
| | ||||
o 3:6f9641995072 (draft) [ ] add n3w_3_c | ||||
Pierre-Yves David
|
r17214 | | | ||
Pierre-Yves David
|
r21978 | | o 2:245bde4270cd (public) [ ] add original_c | ||
|/ | ||||
o 1:7c3bad9141dc (public) [ ] add b | ||||
Pierre-Yves David
|
r17214 | | | ||
Pierre-Yves David
|
r21978 | o 0:1f0dee641bb7 (public) [ ] add a | ||
Pierre-Yves David
|
r17214 | |||
Pierre-Yves David
|
r17831 | $ hg up -q 'desc(n3w_3_c)' | ||
Pierre-Yves David
|
r17214 | $ mkcommit obsolete_e | ||
created new head | ||||
$ hg debugobsolete `getid 'original_e'` `getid 'obsolete_e'` | ||||
Pierre-Yves David
|
r18493 | $ hg outgoing ../tmpf # parasite hg outgoing testin | ||
comparing with ../tmpf | ||||
searching for changes | ||||
Pierre-Yves David
|
r21978 | 6:3de5eca88c00 (draft) [tip ] add obsolete_e | ||
Pierre-Yves David
|
r17214 | $ hg push ../tmpf | ||
pushing to ../tmpf | ||||
searching for changes | ||||
adding changesets | ||||
adding manifests | ||||
adding file changes | ||||
added 1 changesets with 1 changes to 1 files (+1 heads) | ||||
Pierre-Yves David
|
r25351 | 1 new obsolescence markers | ||
Pierre-Yves David
|
r17297 | |||
Pierre-Yves David
|
r22274 | test relevance computation | ||
--------------------------------------- | ||||
Checking simple case of "marker relevance". | ||||
Reminder of the repo situation | ||||
$ hg log --hidden --graph | ||||
@ 6:3de5eca88c00 (draft) [tip ] add obsolete_e | ||||
| | ||||
| x 5:cda648ca50f5 (draft) [ ] add original_e | ||||
| | | ||||
| x 4:94b33453f93b (draft) [ ] add original_d | ||||
|/ | ||||
o 3:6f9641995072 (draft) [ ] add n3w_3_c | ||||
| | ||||
| o 2:245bde4270cd (public) [ ] add original_c | ||||
|/ | ||||
o 1:7c3bad9141dc (public) [ ] add b | ||||
| | ||||
o 0:1f0dee641bb7 (public) [ ] add a | ||||
List of all markers | ||||
$ hg debugobsolete | ||||
Pierre-Yves David
|
r22348 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r22274 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r25118 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||
Pierre-Yves David
|
r22274 | 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | ||
cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test'} (glob) | ||||
List of changesets with no chain | ||||
$ hg debugobsolete --hidden --rev ::2 | ||||
List of changesets that are included on marker chain | ||||
$ hg debugobsolete --hidden --rev 6 | ||||
cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test'} (glob) | ||||
List of changesets with a longer chain, (including a pruned children) | ||||
$ hg debugobsolete --hidden --rev 3 | ||||
1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||||
Pierre-Yves David
|
r22348 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r22274 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | ||||
ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||||
cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||||
List of both | ||||
$ hg debugobsolete --hidden --rev 3::6 | ||||
1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||||
Pierre-Yves David
|
r22348 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} | ||
FUJIWARA Katsunori
|
r23094 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'} | ||
Pierre-Yves David
|
r22274 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||
94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | ||||
ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} | ||||
cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test'} (glob) | ||||
cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} | ||||
Mads Kiilerich
|
r18506 | #if serve | ||
Pierre-Yves David
|
r24733 | Test the debug output for exchange | ||
---------------------------------- | ||||
$ hg pull ../tmpb --config 'experimental.obsmarkers-exchange-debug=True' --config 'experimental.bundle2-exp=True' | ||||
pulling from ../tmpb | ||||
searching for changes | ||||
no changes found | ||||
obsmarker-exchange: 346 bytes received | ||||
Pierre-Yves David
|
r18401 | check hgweb does not explode | ||
==================================== | ||||
$ hg unbundle $TESTDIR/bundles/hgweb+obs.hg | ||||
adding changesets | ||||
adding manifests | ||||
adding file changes | ||||
added 62 changesets with 63 changes to 9 files (+60 heads) | ||||
(run 'hg heads .' to see heads, 'hg merge' to merge) | ||||
$ for node in `hg log -r 'desc(babar_)' --template '{node}\n'`; | ||||
> do | ||||
> hg debugobsolete $node | ||||
> done | ||||
$ hg up tip | ||||
2 files updated, 0 files merged, 0 files removed, 0 files unresolved | ||||
$ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log | ||||
$ cat hg.pid >> $DAEMON_PIDS | ||||
Pierre-Yves David
|
r18426 | check changelog view | ||
Matt Mackall
|
r25472 | $ get-with-headers.py --headeronly localhost:$HGPORT 'shortlog/' | ||
Pierre-Yves David
|
r18426 | 200 Script output follows | ||
Pierre-Yves David
|
r18401 | |||
Pierre-Yves David
|
r18428 | check graph view | ||
Matt Mackall
|
r25472 | $ get-with-headers.py --headeronly localhost:$HGPORT 'graph' | ||
Pierre-Yves David
|
r18428 | 200 Script output follows | ||
Pierre-Yves David
|
r18401 | check filelog view | ||
Matt Mackall
|
r25472 | $ get-with-headers.py --headeronly localhost:$HGPORT 'log/'`hg log -r . -T "{node}"`/'babar' | ||
Pierre-Yves David
|
r18401 | 200 Script output follows | ||
Pierre-Yves David
|
r18522 | |||
Matt Mackall
|
r25472 | $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/68' | ||
Pierre-Yves David
|
r18522 | 200 Script output follows | ||
Matt Mackall
|
r25472 | $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/67' | ||
Matt Mackall
|
r18532 | 404 Not Found | ||
Pierre-Yves David
|
r18522 | [1] | ||
check that web.view config option: | ||||
Matt Mackall
|
r25472 | $ killdaemons.py hg.pid | ||
Pierre-Yves David
|
r18522 | $ cat >> .hg/hgrc << EOF | ||
> [web] | ||||
> view=all | ||||
> EOF | ||||
$ wait | ||||
$ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log | ||||
Matt Mackall
|
r25472 | $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/67' | ||
Pierre-Yves David
|
r18522 | 200 Script output follows | ||
Matt Mackall
|
r25472 | $ killdaemons.py hg.pid | ||
Pierre-Yves David
|
r18401 | |||
Thomas Arendsen Hein
|
r17306 | Checking _enable=False warning if obsolete marker exists | ||
Pierre-Yves David
|
r17297 | |||
Durham Goode
|
r22955 | $ echo '[experimental]' >> $HGRCPATH | ||
$ echo "evolution=" >> $HGRCPATH | ||||
Pierre-Yves David
|
r17297 | $ hg log -r tip | ||
Pierre-Yves David
|
r18401 | obsolete feature not enabled but 68 markers found! | ||
Pierre-Yves David
|
r21978 | 68:c15e9edfca13 (draft) [tip ] add celestine | ||
Pierre-Yves David
|
r18568 | |||
reenable for later test | ||||
Durham Goode
|
r22955 | $ echo '[experimental]' >> $HGRCPATH | ||
$ echo "evolution=createmarkers,exchange" >> $HGRCPATH | ||||
Pierre-Yves David
|
r18568 | |||
Mads Kiilerich
|
r18506 | #endif | ||
Pierre-Yves David
|
r18568 | |||
Test incoming/outcoming with changesets obsoleted remotely, known locally | ||||
=============================================================================== | ||||
This test issue 3805 | ||||
$ hg init repo-issue3805 | ||||
$ cd repo-issue3805 | ||||
Pierre-Yves David
|
r27318 | $ echo "base" > base | ||
$ hg ci -Am "base" | ||||
adding base | ||||
Pierre-Yves David
|
r18568 | $ echo "foo" > foo | ||
$ hg ci -Am "A" | ||||
adding foo | ||||
$ hg clone . ../other-issue3805 | ||||
updating to branch default | ||||
Pierre-Yves David
|
r27318 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | ||
Pierre-Yves David
|
r18568 | $ echo "bar" >> foo | ||
$ hg ci --amend | ||||
$ cd ../other-issue3805 | ||||
$ hg log -G | ||||
Pierre-Yves David
|
r27318 | @ 1:29f0c6921ddd (draft) [tip ] A | ||
| | ||||
o 0:d20a80d4def3 (draft) [ ] base | ||||
Pierre-Yves David
|
r18568 | |||
$ hg log -G -R ../repo-issue3805 | ||||
Pierre-Yves David
|
r27318 | @ 3:323a9c3ddd91 (draft) [tip ] A | ||
| | ||||
o 0:d20a80d4def3 (draft) [ ] base | ||||
Pierre-Yves David
|
r18568 | |||
$ hg incoming | ||||
Simon Heimberg
|
r18679 | comparing with $TESTTMP/tmpe/repo-issue3805 (glob) | ||
Pierre-Yves David
|
r18568 | searching for changes | ||
Pierre-Yves David
|
r27318 | 3:323a9c3ddd91 (draft) [tip ] A | ||
Pierre-Yves David
|
r18568 | $ hg incoming --bundle ../issue3805.hg | ||
Simon Heimberg
|
r18679 | comparing with $TESTTMP/tmpe/repo-issue3805 (glob) | ||
Pierre-Yves David
|
r18568 | searching for changes | ||
Pierre-Yves David
|
r27318 | 3:323a9c3ddd91 (draft) [tip ] A | ||
Pierre-Yves David
|
r18568 | $ hg outgoing | ||
Simon Heimberg
|
r18679 | comparing with $TESTTMP/tmpe/repo-issue3805 (glob) | ||
Pierre-Yves David
|
r18568 | searching for changes | ||
Pierre-Yves David
|
r27319 | 1:29f0c6921ddd (draft) [tip ] A | ||
Pierre-Yves David
|
r18568 | |||
#if serve | ||||
$ hg serve -R ../repo-issue3805 -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log | ||||
$ cat hg.pid >> $DAEMON_PIDS | ||||
$ hg incoming http://localhost:$HGPORT | ||||
comparing with http://localhost:$HGPORT/ | ||||
searching for changes | ||||
Pierre-Yves David
|
r27318 | 2:323a9c3ddd91 (draft) [tip ] A | ||
Pierre-Yves David
|
r18568 | $ hg outgoing http://localhost:$HGPORT | ||
comparing with http://localhost:$HGPORT/ | ||||
searching for changes | ||||
Pierre-Yves David
|
r27319 | 1:29f0c6921ddd (draft) [tip ] A | ||
Pierre-Yves David
|
r18568 | |||
Matt Mackall
|
r25474 | $ killdaemons.py | ||
Pierre-Yves David
|
r18568 | |||
#endif | ||||
Pierre-Yves David
|
r18617 | |||
This test issue 3814 | ||||
(nothing to push but locally hidden changeset) | ||||
$ cd .. | ||||
$ hg init repo-issue3814 | ||||
$ cd repo-issue3805 | ||||
Pierre-Yves David
|
r27318 | $ hg push -r 323a9c3ddd91 ../repo-issue3814 | ||
Pierre-Yves David
|
r18617 | pushing to ../repo-issue3814 | ||
searching for changes | ||||
adding changesets | ||||
adding manifests | ||||
adding file changes | ||||
Pierre-Yves David
|
r27318 | added 2 changesets with 2 changes to 2 files | ||
Pierre-Yves David
|
r25351 | 2 new obsolescence markers | ||
Pierre-Yves David
|
r18617 | $ hg out ../repo-issue3814 | ||
comparing with ../repo-issue3814 | ||||
searching for changes | ||||
no changes found | ||||
[1] | ||||
Sean Farley
|
r20807 | Test that a local tag blocks a changeset from being hidden | ||
Pierre-Yves David
|
r18617 | |||
Pierre-Yves David
|
r27318 | $ hg tag -l visible -r 1 --hidden | ||
Sean Farley
|
r20807 | $ hg log -G | ||
Pierre-Yves David
|
r27318 | @ 3:323a9c3ddd91 (draft) [tip ] A | ||
| | ||||
| x 1:29f0c6921ddd (draft) [visible ] A | ||||
|/ | ||||
o 0:d20a80d4def3 (draft) [ ] base | ||||
Sean Farley
|
r20807 | |||
Angel Ezquerra
|
r21823 | Test that removing a local tag does not cause some commands to fail | ||
$ hg tag -l -r tip tiptag | ||||
$ hg tags | ||||
Pierre-Yves David
|
r27318 | tiptag 3:323a9c3ddd91 | ||
tip 3:323a9c3ddd91 | ||||
visible 1:29f0c6921ddd | ||||
Angel Ezquerra
|
r21823 | $ hg --config extensions.strip= strip -r tip --no-backup | ||
0 files updated, 0 files merged, 1 files removed, 0 files unresolved | ||||
$ hg tags | ||||
Pierre-Yves David
|
r27318 | visible 1:29f0c6921ddd | ||
tip 1:29f0c6921ddd | ||||
Matt Harbison
|
r24113 | |||
Yuya Nishihara
|
r24882 | Test bundle overlay onto hidden revision | ||
$ cd .. | ||||
$ hg init repo-bundleoverlay | ||||
$ cd repo-bundleoverlay | ||||
$ echo "A" > foo | ||||
$ hg ci -Am "A" | ||||
adding foo | ||||
$ echo "B" >> foo | ||||
$ hg ci -m "B" | ||||
$ hg up 0 | ||||
1 files updated, 0 files merged, 0 files removed, 0 files unresolved | ||||
$ echo "C" >> foo | ||||
$ hg ci -m "C" | ||||
created new head | ||||
$ hg log -G | ||||
@ 2:c186d7714947 (draft) [tip ] C | ||||
| | ||||
| o 1:44526ebb0f98 (draft) [ ] B | ||||
|/ | ||||
o 0:4b34ecfb0d56 (draft) [ ] A | ||||
$ hg clone -r1 . ../other-bundleoverlay | ||||
adding changesets | ||||
adding manifests | ||||
adding file changes | ||||
added 2 changesets with 2 changes to 1 files | ||||
updating to branch default | ||||
1 files updated, 0 files merged, 0 files removed, 0 files unresolved | ||||
$ cd ../other-bundleoverlay | ||||
$ echo "B+" >> foo | ||||
$ hg ci --amend -m "B+" | ||||
$ hg log -G --hidden | ||||
@ 3:b7d587542d40 (draft) [tip ] B+ | ||||
| | ||||
| x 2:eb95e9297e18 (draft) [ ] temporary amend commit for 44526ebb0f98 | ||||
| | | ||||
| x 1:44526ebb0f98 (draft) [ ] B | ||||
|/ | ||||
o 0:4b34ecfb0d56 (draft) [ ] A | ||||
$ hg incoming ../repo-bundleoverlay --bundle ../bundleoverlay.hg | ||||
comparing with ../repo-bundleoverlay | ||||
searching for changes | ||||
1:44526ebb0f98 (draft) [ ] B | ||||
2:c186d7714947 (draft) [tip ] C | ||||
$ hg log -G -R ../bundleoverlay.hg | ||||
o 4:c186d7714947 (draft) [tip ] C | ||||
| | ||||
| @ 3:b7d587542d40 (draft) [ ] B+ | ||||
|/ | ||||
o 0:4b34ecfb0d56 (draft) [ ] A | ||||
Anton Shestakov
|
r24136 | #if serve | ||
Test issue 4506 | ||||
$ cd .. | ||||
$ hg init repo-issue4506 | ||||
$ cd repo-issue4506 | ||||
$ echo "0" > foo | ||||
$ hg add foo | ||||
$ hg ci -m "content-0" | ||||
$ hg up null | ||||
0 files updated, 0 files merged, 1 files removed, 0 files unresolved | ||||
$ echo "1" > bar | ||||
$ hg add bar | ||||
$ hg ci -m "content-1" | ||||
created new head | ||||
$ hg up 0 | ||||
1 files updated, 0 files merged, 1 files removed, 0 files unresolved | ||||
$ hg graft 1 | ||||
grafting 1:1c9eddb02162 "content-1" (tip) | ||||
$ hg debugobsolete `hg log -r1 -T'{node}'` `hg log -r2 -T'{node}'` | ||||
$ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log | ||||
$ cat hg.pid >> $DAEMON_PIDS | ||||
Matt Mackall
|
r25472 | $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/1' | ||
Anton Shestakov
|
r24136 | 404 Not Found | ||
[1] | ||||
Matt Mackall
|
r25472 | $ get-with-headers.py --headeronly localhost:$HGPORT 'file/tip/bar' | ||
Anton Shestakov
|
r24136 | 200 Script output follows | ||
Matt Mackall
|
r25472 | $ get-with-headers.py --headeronly localhost:$HGPORT 'annotate/tip/bar' | ||
Anton Shestakov
|
r24136 | 200 Script output follows | ||
Matt Mackall
|
r25474 | $ killdaemons.py | ||
Anton Shestakov
|
r24136 | |||
#endif | ||||
Laurent Charignon
|
r25297 | Test heads computation on pending index changes with obsolescence markers | ||
$ cd .. | ||||
$ cat >$TESTTMP/test_extension.py << EOF | ||||
> from mercurial import cmdutil | ||||
> from mercurial.i18n import _ | ||||
> | ||||
> cmdtable = {} | ||||
> command = cmdutil.command(cmdtable) | ||||
> @command("amendtransient",[], _('hg amendtransient [rev]')) | ||||
> def amend(ui, repo, *pats, **opts): | ||||
> def commitfunc(ui, repo, message, match, opts): | ||||
> return repo.commit(message, repo['.'].user(), repo['.'].date(), match) | ||||
> opts['message'] = 'Test' | ||||
> opts['logfile'] = None | ||||
> cmdutil.amend(ui, repo, commitfunc, repo['.'], {}, pats, opts) | ||||
> print repo.changelog.headrevs() | ||||
> EOF | ||||
$ cat >> $HGRCPATH << EOF | ||||
> [extensions] | ||||
> testextension=$TESTTMP/test_extension.py | ||||
> EOF | ||||
$ hg init repo-issue-nativerevs-pending-changes | ||||
$ cd repo-issue-nativerevs-pending-changes | ||||
$ mkcommit a | ||||
$ mkcommit b | ||||
$ hg up ".^" | ||||
0 files updated, 0 files merged, 1 files removed, 0 files unresolved | ||||
$ echo aa > a | ||||
$ hg amendtransient | ||||
[1, 3] | ||||
Laurent Charignon
|
r25569 | |||
Test cache consistency for the visible filter | ||||
1) We want to make sure that the cached filtered revs are invalidated when | ||||
bookmarks change | ||||
$ cd .. | ||||
$ cat >$TESTTMP/test_extension.py << EOF | ||||
> from mercurial import cmdutil, extensions, bookmarks, repoview | ||||
> def _bookmarkchanged(orig, bkmstoreinst, *args, **kwargs): | ||||
> repo = bkmstoreinst._repo | ||||
> ret = orig(bkmstoreinst, *args, **kwargs) | ||||
> hidden1 = repoview.computehidden(repo) | ||||
> hidden = repoview.filterrevs(repo, 'visible') | ||||
> if sorted(hidden1) != sorted(hidden): | ||||
> print "cache inconsistency" | ||||
> return ret | ||||
> def extsetup(ui): | ||||
> extensions.wrapfunction(bookmarks.bmstore, 'write', _bookmarkchanged) | ||||
> EOF | ||||
$ hg init repo-cache-inconsistency | ||||
$ cd repo-issue-nativerevs-pending-changes | ||||
$ mkcommit a | ||||
a already tracked! | ||||
$ mkcommit b | ||||
$ hg id | ||||
13bedc178fce tip | ||||
$ echo "hello" > b | ||||
$ hg commit --amend -m "message" | ||||
$ hg book bookb -r 13bedc178fce --hidden | ||||
$ hg log -r 13bedc178fce | ||||
5:13bedc178fce (draft) [ bookb] add b | ||||
$ hg book -d bookb | ||||
$ hg log -r 13bedc178fce | ||||
abort: hidden revision '13bedc178fce'! | ||||
(use --hidden to access hidden revisions) | ||||
[255] | ||||