Mercurial > hg
diff tests/test-treemanifest.t @ 27432:77d25b913f80
changegroup: introduce cg3, which has support for exchanging treemanifests
I'm not entirely happy with using a trailing / on a "file" entry for
transferring a treemanifest. We've discussed putting some flags on
each file header[0], but I'm unconvinced that's actually any better:
if we were going to add another feature to the cg format we'd still be
doing a version bump anyway to cg4, so I'm inclined to not spend time
coming up with a more sophisticated format until we actually know what
the next feature we want to stuff in a changegroup will be.
Test changes outside test-treemanifest.t are only due to the new CG3
bundlecap showing up in the wire protocol.
Many thanks to adgar@google.com and martinvonz@google.com for helping
me with various odd corners of the changegroup and treemanifest API.
0: It's not hard refactoring, nor is it a lot of work. I'm just
disinclined to do speculative work when it's not clear what the
customer would actually be.
author | Augie Fackler <augie@google.com> |
---|---|
date | Fri, 11 Dec 2015 11:23:49 -0500 |
parents | 2a31433a59ba |
children | 29cfc474c5fd |
line wrap: on
line diff
--- a/tests/test-treemanifest.t Fri Dec 18 14:40:11 2015 -0600 +++ b/tests/test-treemanifest.t Fri Dec 11 11:23:49 2015 -0500 @@ -388,3 +388,56 @@ $ mv oldmf2 .hg/store/meta/b/foo $ mv oldmf3 .hg/store/meta/b/bar/orange +Add some more changes to the deep repo + $ echo narf >> b/bar/fruits.txt + $ hg ci -m narf + $ echo troz >> b/bar/orange/fly/gnat.py + $ hg ci -m troz + +Test cloning a treemanifest repo over http. + $ hg serve -p $HGPORT -d --pid-file=hg.pid --errorlog=errors.log + $ cat hg.pid >> $DAEMON_PIDS + $ cd .. +We can clone even with the knob turned off and we'll get a treemanifest repo. + $ hg clone --config experimental.treemanifest=False \ + > http://localhost:$HGPORT deepclone + requesting all changes + adding changesets + adding manifests + adding file changes + added 3 changesets with 10 changes to 8 files + updating to branch default + 8 files updated, 0 files merged, 0 files removed, 0 files unresolved +No server errors. + $ cat deeprepo/errors.log +requires got updated to include treemanifest + $ cat deepclone/.hg/requires | grep treemanifest + treemanifest +Tree manifest revlogs exist. + $ find deepclone/.hg/store/meta | sort + deepclone/.hg/store/meta + deepclone/.hg/store/meta/a + deepclone/.hg/store/meta/a/00manifest.i + deepclone/.hg/store/meta/b + deepclone/.hg/store/meta/b/00manifest.i + deepclone/.hg/store/meta/b/bar + deepclone/.hg/store/meta/b/bar/00manifest.i + deepclone/.hg/store/meta/b/bar/orange + deepclone/.hg/store/meta/b/bar/orange/00manifest.i + deepclone/.hg/store/meta/b/bar/orange/fly + deepclone/.hg/store/meta/b/bar/orange/fly/00manifest.i + deepclone/.hg/store/meta/b/foo + deepclone/.hg/store/meta/b/foo/00manifest.i + deepclone/.hg/store/meta/b/foo/apple + deepclone/.hg/store/meta/b/foo/apple/00manifest.i + deepclone/.hg/store/meta/b/foo/apple/bees + deepclone/.hg/store/meta/b/foo/apple/bees/00manifest.i +Verify passes. + $ cd deepclone + $ hg verify + checking changesets + checking manifests + crosschecking files in changesets and manifests + checking files + 8 files, 3 changesets, 10 total revisions + $ cd ..