Show More
@@ -80,7 +80,7 b' def combineresults(results):' | |||||
80 | return result |
|
80 | return result | |
81 |
|
81 | |||
82 | bundletypes = { |
|
82 | bundletypes = { | |
83 |
"": ("", |
|
83 | "": ("", None), # only when using unbundle on ssh and old http servers | |
84 | # since the unification ssh accepts a header but there |
|
84 | # since the unification ssh accepts a header but there | |
85 | # is no capability signaling it. |
|
85 | # is no capability signaling it. | |
86 | "HG20": (), # special-cased below |
|
86 | "HG20": (), # special-cased below |
@@ -114,6 +114,36 b' expect success, server lacks the unbundl' | |||||
114 | $ hg rollback |
|
114 | $ hg rollback | |
115 | repository tip rolled back to revision 0 (undo serve) |
|
115 | repository tip rolled back to revision 0 (undo serve) | |
116 |
|
116 | |||
|
117 | expect success, pre-d1b16a746db6 server supports the unbundle capability, but | |||
|
118 | has no parameter | |||
|
119 | ||||
|
120 | $ cat <<EOF > notcapable-unbundleparam.py | |||
|
121 | > from mercurial import extensions, httppeer | |||
|
122 | > def capable(orig, self, name): | |||
|
123 | > if name == 'unbundle': | |||
|
124 | > return True | |||
|
125 | > return orig(self, name) | |||
|
126 | > def uisetup(ui): | |||
|
127 | > extensions.wrapfunction(httppeer.httppeer, 'capable', capable) | |||
|
128 | > EOF | |||
|
129 | $ cp $HGRCPATH $HGRCPATH.orig | |||
|
130 | $ cat <<EOF >> $HGRCPATH | |||
|
131 | > [extensions] | |||
|
132 | > notcapable-unbundleparam = `pwd`/notcapable-unbundleparam.py | |||
|
133 | > EOF | |||
|
134 | $ req | |||
|
135 | pushing to http://localhost:$HGPORT/ | |||
|
136 | searching for changes | |||
|
137 | remote: adding changesets | |||
|
138 | remote: adding manifests | |||
|
139 | remote: adding file changes | |||
|
140 | remote: added 1 changesets with 1 changes to 1 files | |||
|
141 | remote: changegroup hook: * (glob) | |||
|
142 | % serve errors | |||
|
143 | $ hg rollback | |||
|
144 | repository tip rolled back to revision 0 (undo serve) | |||
|
145 | $ mv $HGRCPATH.orig $HGRCPATH | |||
|
146 | ||||
117 | expect push success, phase change failure |
|
147 | expect push success, phase change failure | |
118 |
|
148 | |||
119 | $ cat > .hg/hgrc <<EOF |
|
149 | $ cat > .hg/hgrc <<EOF |
General Comments 0
You need to be logged in to leave comments.
Login now