Mercurial > public > mercurial-scm > hg
annotate tests/test-push-http.t @ 45892:06b64fabf91c
copies: cache the ancestor checking call when tracing copy
A good share of the time spent in this function is spent doing ancestors
checking. To avoid spending time in duplicated call, we cache the result of
calls.
In the slower case, this provide a quite significant performance boost. Below
are the result for a set of selected pairs (many of them pathological):
(And further down is another table that summarize the current state of filelog
based vs changeset base copy tracing)
The benchmark have been configured to be killed after 6 minutes of runtime,
which mean that any detect slower than 2 minutes will be marked as "killed".
This drop some useful information about how much slower these case are? but also
prevent 99% of the benchmark time to be spent on case that can be labelled "very
slow" anyway.
Repo Case Source-Rev Dest-Rev Old-Time New-Time Difference Factor
------------------------------------------------------------------------------------------------------------------------------------
mercurial x_revs_x_added_0_copies ad6b123de1c7 39cfcef4f463 : 0.000044 s, 0.000044 s, +0.000000 s, ? 1.0000
mercurial x_revs_x_added_x_copies 2b1c78674230 0c1d10351869 : 0.000138 s, 0.000138 s, +0.000000 s, ? 1.0000
mercurial x000_revs_x000_added_x_copies 81f8ff2a9bf2 dd3267698d84 : 0.005067 s, 0.005052 s, -0.000015 s, ? 0.9970
pypy x_revs_x_added_0_copies aed021ee8ae8 099ed31b181b : 0.000218 s, 0.000219 s, +0.000001 s, ? 1.0046
pypy x_revs_x000_added_0_copies 4aa4e1f8e19a 359343b9ac0e : 0.000053 s, 0.000055 s, +0.000002 s, ? 1.0377
pypy x_revs_x_added_x_copies ac52eb7bbbb0 72e022663155 : 0.000125 s, 0.000128 s, +0.000003 s, ? 1.0240
pypy x_revs_x00_added_x_copies c3b14617fbd7 ace7255d9a26 : 0.001098 s, 0.001089 s, -0.000009 s, ? 0.9918
pypy x_revs_x000_added_x000_copies df6f7a526b60 a83dc6a2d56f : 0.017546 s, 0.017407 s, -0.000139 s, ? 0.9921
pypy x000_revs_xx00_added_0_copies 89a76aede314 2f22446ff07e : 0.096723 s, 0.094175 s, -0.002548 s, ? 0.9737
pypy x000_revs_x000_added_x_copies 8a3b5bfd266e 2c68e87c3efe : 0.271796 s, 0.238009 s, -0.033787 s, ? 0.8757
pypy x000_revs_x000_added_x000_copies 89a76aede314 7b3dda341c84 : 0.128602 s, 0.125876 s, -0.002726 s, ? 0.9788
pypy x0000_revs_x_added_0_copies d1defd0dc478 c9cb1334cc78 : 7.086742 s, 3.581556 s, -3.505186 s, ? 0.5054
pypy x0000_revs_xx000_added_0_copies bf2c629d0071 4ffed77c095c : 0.016634 s, 0.016721 s, +0.000087 s, ? 1.0052
pypy x0000_revs_xx000_added_x000_copies 08ea3258278e d9fa043f30c0 : 0.254225 s, 0.242367 s, -0.011858 s, ? 0.9534
netbeans x_revs_x_added_0_copies fb0955ffcbcd a01e9239f9e7 : 0.000166 s, 0.000165 s, -0.000001 s, ? 0.9940
netbeans x_revs_x000_added_0_copies 6f360122949f 20eb231cc7d0 : 0.000118 s, 0.000114 s, -0.000004 s, ? 0.9661
netbeans x_revs_x_added_x_copies 1ada3faf6fb6 5a39d12eecf4 : 0.000296 s, 0.000296 s, +0.000000 s, ? 1.0000
netbeans x_revs_x00_added_x_copies 35be93ba1e2c 9eec5e90c05f : 0.001137 s, 0.001124 s, -0.000013 s, ? 0.9886
netbeans x000_revs_xx00_added_0_copies eac3045b4fdd 51d4ae7f1290 : 0.014133 s, 0.013060 s, -0.001073 s, ? 0.9241
netbeans x000_revs_x000_added_x_copies e2063d266acd 6081d72689dc : 0.016988 s, 0.017112 s, +0.000124 s, ? 1.0073
netbeans x000_revs_x000_added_x000_copies ff453e9fee32 411350406ec2 : 0.676361 s, 0.660350 s, -0.016011 s, ? 0.9763
netbeans x0000_revs_xx000_added_x000_copies 588c2d1ced70 1aad62e59ddd : 12.515149 s, 10.032499 s, -2.482650 s, ? 0.8016
mozilla-central x_revs_x_added_0_copies 3697f962bb7b 7015fcdd43a2 : 0.000186 s, 0.000189 s, +0.000003 s, ? 1.0161
mozilla-central x_revs_x000_added_0_copies dd390860c6c9 40d0c5bed75d : 0.000459 s, 0.000462 s, +0.000003 s, ? 1.0065
mozilla-central x_revs_x_added_x_copies 8d198483ae3b 14207ffc2b2f : 0.000273 s, 0.000270 s, -0.000003 s, ? 0.9890
mozilla-central x_revs_x00_added_x_copies 98cbc58cc6bc 446a150332c3 : 0.001503 s, 0.001474 s, -0.000029 s, ? 0.9807
mozilla-central x_revs_x000_added_x000_copies 3c684b4b8f68 0a5e72d1b479 : 0.004862 s, 0.004806 s, -0.000056 s, ? 0.9885
mozilla-central x_revs_x0000_added_x0000_copies effb563bb7e5 c07a39dc4e80 : 0.088291 s, 0.085150 s, -0.003141 s, ? 0.9644
mozilla-central x000_revs_xx00_added_0_copies 6100d773079a 04a55431795e : 0.007113 s, 0.007064 s, -0.000049 s, ? 0.9931
mozilla-central x000_revs_x000_added_x_copies 9f17a6fc04f9 2d37b966abed : 0.004687 s, 0.004741 s, +0.000054 s, ? 1.0115
mozilla-central x000_revs_x000_added_x000_copies 7c97034feb78 4407bd0c6330 : 0.198710 s, 0.190133 s, -0.008577 s, ? 0.9568
mozilla-central x0000_revs_xx000_added_0_copies 9eec5917337d 67118cc6dcad : 0.036068 s, 0.035651 s, -0.000417 s, ? 0.9884
mozilla-central x0000_revs_xx000_added_x000_copies f78c615a656c 96a38b690156 : 0.465362 s, 0.440694 s, -0.024668 s, ? 0.9470
mozilla-central x00000_revs_x0000_added_x0000_copies 6832ae71433c 4c222a1d9a00 : 24.519684 s, 18.454163 s, -6.065521 s, ? 0.7526
mozilla-central x00000_revs_x00000_added_x000_copies 76caed42cf7c 1daa622bbe42 : 42.711897 s, 31.562719 s, -11.149178 s, ? 0.7390
mozilla-try x_revs_x_added_0_copies aaf6dde0deb8 9790f499805a : 0.001201 s, 0.001189 s, -0.000012 s, ? 0.9900
mozilla-try x_revs_x000_added_0_copies d8d0222927b4 5bb8ce8c7450 : 0.001216 s, 0.001204 s, -0.000012 s, ? 0.9901
mozilla-try x_revs_x_added_x_copies 092fcca11bdb 936255a0384a : 0.000595 s, 0.000586 s, -0.000009 s, ? 0.9849
mozilla-try x_revs_x00_added_x_copies b53d2fadbdb5 017afae788ec : 0.001856 s, 0.001845 s, -0.000011 s, ? 0.9941
mozilla-try x_revs_x000_added_x000_copies 20408ad61ce5 6f0ee96e21ad : 0.064936 s, 0.063822 s, -0.001114 s, ? 0.9828
mozilla-try x_revs_x0000_added_x0000_copies effb563bb7e5 c07a39dc4e80 : 0.090601 s, 0.088038 s, -0.002563 s, ? 0.9717
mozilla-try x000_revs_xx00_added_0_copies 6100d773079a 04a55431795e : 0.007510 s, 0.007389 s, -0.000121 s, ? 0.9839
mozilla-try x000_revs_x000_added_x_copies 9f17a6fc04f9 2d37b966abed : 0.004911 s, 0.004868 s, -0.000043 s, ? 0.9912
mozilla-try x000_revs_x000_added_x000_copies 1346fd0130e4 4c65cbdabc1f : 0.233231 s, 0.222450 s, -0.010781 s, ? 0.9538
mozilla-try x0000_revs_x_added_0_copies 63519bfd42ee a36a2a865d92 : 0.419989 s, 0.370675 s, -0.049314 s, ? 0.8826
mozilla-try x0000_revs_x_added_x_copies 9fe69ff0762d bcabf2a78927 : 0.401521 s, 0.358020 s, -0.043501 s, ? 0.8917
mozilla-try x0000_revs_xx000_added_x_copies 156f6e2674f2 4d0f2c178e66 : 0.179555 s, 0.145235 s, -0.034320 s, ? 0.8089
mozilla-try x0000_revs_xx000_added_0_copies 9eec5917337d 67118cc6dcad : 0.038004 s, 0.037606 s, -0.000398 s, ? 0.9895
mozilla-try x0000_revs_xx000_added_x000_copies 89294cd501d9 7ccb2fc7ccb5 : 52.838482 s, 7.382439 s, -45.456043 s, ? 0.1397
mozilla-try x0000_revs_x0000_added_x0000_copies e928c65095ed e951f4ad123a : 8.705874 s, 7.273506 s, -1.432368 s, ? 0.8355
mozilla-try x00000_revs_x00000_added_0_copies dc8a3ca7010e d16fde900c9c : 1.126708 s, 1.074593 s, -0.052115 s, ? 0.9537
mozilla-try x00000_revs_x0000_added_x0000_copies 8d3fafa80d4b eb884023b810 : 83.854020 s, 27.746195 s, -56.107825 s, ? 0.3309
Below is a table comparing the runtime of the current "filelog centric"
algorithm, with the "changeset centric" one, we just modified.
The changeset centric algorithm is a significant win in many scenario, but they
are still various cases where it is quite slower. When many revision has to be
considered the cost of retrieving the copy information, creating new
dictionaries, merging dictionaries and checking if revision are ancestors of
each other can slow things down.
The rest of this series, will introduce a rust version of the copy tracing code
to deal with most of theses issues.
Repo Case Source-Rev Dest-Rev filelog sidedata Difference Factor
---------------------------------------------------------------------------------------------------------------------------------------
mercurial x_revs_x_added_0_copies ad6b123de1c7 39cfcef4f463 : 0.000914 s, 0.000044 s, - 0.000870 s, ? 0.048140
mercurial x_revs_x_added_x_copies 2b1c78674230 0c1d10351869 : 0.001812 s, 0.000138 s, - 0.001674 s, ? 0.076159
mercurial x000_revs_x000_added_x_copies 81f8ff2a9bf2 dd3267698d84 : 0.017954 s, 0.005052 s, - 0.012902 s, ? 0.281386
pypy x_revs_x_added_0_copies aed021ee8ae8 099ed31b181b : 0.001509 s, 0.000219 s, - 0.001290 s, ? 0.145129
pypy x_revs_x000_added_0_copies 4aa4e1f8e19a 359343b9ac0e : 0.206881 s, 0.000055 s, - 0.206826 s, ? 0.000266
pypy x_revs_x_added_x_copies ac52eb7bbbb0 72e022663155 : 0.016951 s, 0.000128 s, - 0.016823 s, ? 0.007551
pypy x_revs_x00_added_x_copies c3b14617fbd7 ace7255d9a26 : 0.019096 s, 0.001089 s, - 0.018007 s, ? 0.057028
pypy x_revs_x000_added_x000_copies df6f7a526b60 a83dc6a2d56f : 0.762506 s, 0.017407 s, - 0.745099 s, ? 0.022829
pypy x000_revs_xx00_added_0_copies 89a76aede314 2f22446ff07e : 1.179211 s, 0.094175 s, - 1.085036 s, ? 0.079863
pypy x000_revs_x000_added_x_copies 8a3b5bfd266e 2c68e87c3efe : 1.249058 s, 0.238009 s, - 1.011049 s, ? 0.190551
pypy x000_revs_x000_added_x000_copies 89a76aede314 7b3dda341c84 : 1.614107 s, 0.125876 s, - 1.488231 s, ? 0.077985
pypy x0000_revs_x_added_0_copies d1defd0dc478 c9cb1334cc78 : 0.001064 s, 3.581556 s, + 3.580492 s, ? 3366.124060
pypy x0000_revs_xx000_added_0_copies bf2c629d0071 4ffed77c095c : 1.061275 s, 0.016721 s, - 1.044554 s, ? 0.015756
pypy x0000_revs_xx000_added_x000_copies 08ea3258278e d9fa043f30c0 : 1.341119 s, 0.242367 s, - 1.098752 s, ? 0.180720
netbeans x_revs_x_added_0_copies fb0955ffcbcd a01e9239f9e7 : 0.027803 s, 0.000165 s, - 0.027638 s, ? 0.005935
netbeans x_revs_x000_added_0_copies 6f360122949f 20eb231cc7d0 : 0.130014 s, 0.000114 s, - 0.129900 s, ? 0.000877
netbeans x_revs_x_added_x_copies 1ada3faf6fb6 5a39d12eecf4 : 0.024990 s, 0.000296 s, - 0.024694 s, ? 0.011845
netbeans x_revs_x00_added_x_copies 35be93ba1e2c 9eec5e90c05f : 0.052201 s, 0.001124 s, - 0.051077 s, ? 0.021532
netbeans x000_revs_xx00_added_0_copies eac3045b4fdd 51d4ae7f1290 : 0.037642 s, 0.013060 s, - 0.024582 s, ? 0.346953
netbeans x000_revs_x000_added_x_copies e2063d266acd 6081d72689dc : 0.197086 s, 0.017112 s, - 0.179974 s, ? 0.086825
netbeans x000_revs_x000_added_x000_copies ff453e9fee32 411350406ec2 : 0.935148 s, 0.660350 s, - 0.274798 s, ? 0.706145
netbeans x0000_revs_xx000_added_x000_copies 588c2d1ced70 1aad62e59ddd : 3.920674 s, 10.032499 s, + 6.111825 s, ? 2.558871
mozilla-central x_revs_x_added_0_copies 3697f962bb7b 7015fcdd43a2 : 0.024232 s, 0.000189 s, - 0.024043 s, ? 0.007800
mozilla-central x_revs_x000_added_0_copies dd390860c6c9 40d0c5bed75d : 0.141483 s, 0.000462 s, - 0.141021 s, ? 0.003265
mozilla-central x_revs_x_added_x_copies 8d198483ae3b 14207ffc2b2f : 0.025775 s, 0.000270 s, - 0.025505 s, ? 0.010475
mozilla-central x_revs_x00_added_x_copies 98cbc58cc6bc 446a150332c3 : 0.084922 s, 0.001474 s, - 0.083448 s, ? 0.017357
mozilla-central x_revs_x000_added_x000_copies 3c684b4b8f68 0a5e72d1b479 : 0.194784 s, 0.004806 s, - 0.189978 s, ? 0.024673
mozilla-central x_revs_x0000_added_x0000_copies effb563bb7e5 c07a39dc4e80 : 2.161103 s, 0.085150 s, - 2.075953 s, ? 0.039401
mozilla-central x000_revs_xx00_added_0_copies 6100d773079a 04a55431795e : 0.089347 s, 0.007064 s, - 0.082283 s, ? 0.079063
mozilla-central x000_revs_x000_added_x_copies 9f17a6fc04f9 2d37b966abed : 0.732171 s, 0.004741 s, - 0.727430 s, ? 0.006475
mozilla-central x000_revs_x000_added_x000_copies 7c97034feb78 4407bd0c6330 : 1.157287 s, 0.190133 s, - 0.967154 s, ? 0.164292
mozilla-central x0000_revs_xx000_added_0_copies 9eec5917337d 67118cc6dcad : 6.726568 s, 0.035651 s, - 6.690917 s, ? 0.005300
mozilla-central x0000_revs_xx000_added_x000_copies f78c615a656c 96a38b690156 : 3.266229 s, 0.440694 s, - 2.825535 s, ? 0.134924
mozilla-central x00000_revs_x0000_added_x0000_copies 6832ae71433c 4c222a1d9a00 : 15.860534 s, 18.454163 s, + 2.593629 s, ? 1.163527
mozilla-central x00000_revs_x00000_added_x000_copies 76caed42cf7c 1daa622bbe42 : 20.450475 s, 31.562719 s, +11.112244 s, ? 1.543373
mozilla-try x_revs_x_added_0_copies aaf6dde0deb8 9790f499805a : 0.080442 s, 0.001189 s, - 0.079253 s, ? 0.014781
mozilla-try x_revs_x000_added_0_copies d8d0222927b4 5bb8ce8c7450 : 0.497672 s, 0.001204 s, - 0.496468 s, ? 0.002419
mozilla-try x_revs_x_added_x_copies 092fcca11bdb 936255a0384a : 0.021183 s, 0.000586 s, - 0.020597 s, ? 0.027664
mozilla-try x_revs_x00_added_x_copies b53d2fadbdb5 017afae788ec : 0.230991 s, 0.001845 s, - 0.229146 s, ? 0.007987
mozilla-try x_revs_x000_added_x000_copies 20408ad61ce5 6f0ee96e21ad : 1.118461 s, 0.063822 s, - 1.054639 s, ? 0.057062
mozilla-try x_revs_x0000_added_x0000_copies effb563bb7e5 c07a39dc4e80 : 2.206083 s, 0.088038 s, - 2.118045 s, ? 0.039907
mozilla-try x000_revs_xx00_added_0_copies 6100d773079a 04a55431795e : 0.089404 s, 0.007389 s, - 0.082015 s, ? 0.082647
mozilla-try x000_revs_x000_added_x_copies 9f17a6fc04f9 2d37b966abed : 0.733043 s, 0.004868 s, - 0.728175 s, ? 0.006641
mozilla-try x000_revs_x000_added_x000_copies 1346fd0130e4 4c65cbdabc1f : 1.163367 s, 0.222450 s, - 0.940917 s, ? 0.191212
mozilla-try x0000_revs_x_added_0_copies 63519bfd42ee a36a2a865d92 : 0.085456 s, 0.370675 s, + 0.285219 s, ? 4.337612
mozilla-try x0000_revs_x_added_x_copies 9fe69ff0762d bcabf2a78927 : 0.083601 s, 0.358020 s, + 0.274419 s, ? 4.282485
mozilla-try x0000_revs_xx000_added_x_copies 156f6e2674f2 4d0f2c178e66 : 7.366614 s, 0.145235 s, - 7.221379 s, ? 0.019715
mozilla-try x0000_revs_xx000_added_0_copies 9eec5917337d 67118cc6dcad : 6.664464 s, 0.037606 s, - 6.626858 s, ? 0.005643
mozilla-try x0000_revs_xx000_added_x000_copies 89294cd501d9 7ccb2fc7ccb5 : 7.467836 s, 7.382439 s, - 0.085397 s, ? 0.988565
mozilla-try x0000_revs_x0000_added_x0000_copies e928c65095ed e951f4ad123a : 9.801294 s, 7.273506 s, - 2.527788 s, ? 0.742097
mozilla-try x00000_revs_x_added_0_copies 6a320851d377 1ebb79acd503 : 0.091886 s, killed
mozilla-try x00000_revs_x00000_added_0_copies dc8a3ca7010e d16fde900c9c : 26.491140 s, 1.074593 s, -25.416547 s, ? 0.040564
mozilla-try x00000_revs_x_added_x_copies 5173c4b6f97c 95d83ee7242d : 0.092863 s, killed
mozilla-try x00000_revs_x000_added_x_copies 9126823d0e9c ca82787bb23c : 0.226823 s, killed
mozilla-try x00000_revs_x0000_added_x0000_copies 8d3fafa80d4b eb884023b810 : 18.914630 s, 27.746195 s, + 8.831565 s, ? 1.466917
mozilla-try x00000_revs_x00000_added_x0000_copies 1b661134e2ca 1ae03d022d6d : 21.198903 s, killed
mozilla-try x00000_revs_x00000_added_x000_copies 9b2a99adc05e 8e29777b48e6 : 24.952268 s, killed
Differential Revision: https://phab.mercurial-scm.org/D9296
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Mon, 02 Nov 2020 11:03:56 +0100 |
parents | ebee234d952a |
children |
rev | line source |
---|---|
38021
538e850ae737
tests: mark tests that fail when using chg as #require no-chg
Kyle Lippincott <spectral@google.com>
parents:
37845
diff
changeset
|
1 #require no-chg |
538e850ae737
tests: mark tests that fail when using chg as #require no-chg
Kyle Lippincott <spectral@google.com>
parents:
37845
diff
changeset
|
2 |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
3 #testcases bundle1 bundle2 |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
4 |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
5 #if bundle1 |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
6 $ cat << EOF >> $HGRCPATH |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
7 > [devel] |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
8 > # This test is dedicated to interaction through old bundle |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
9 > legacy.exchange = bundle1 |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
10 > EOF |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
11 #endif |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
12 |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
13 $ hg init test |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
14 $ cd test |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
15 $ echo a > a |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
16 $ hg ci -Ama |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
17 adding a |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
18 $ cd .. |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
19 $ hg clone test test2 |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
20 updating to branch default |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
21 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
22 $ cd test2 |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
23 $ echo a >> a |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
24 $ hg ci -mb |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
25 $ req() { |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
26 > hg $1 serve -p $HGPORT -d --pid-file=hg.pid -E errors.log |
12743
4c4aeaab2339
check-code: add 'no tab indent' check for unified tests
Adrian Buehlmann <adrian@cadifra.com>
parents:
12643
diff
changeset
|
27 > cat hg.pid >> $DAEMON_PIDS |
4c4aeaab2339
check-code: add 'no tab indent' check for unified tests
Adrian Buehlmann <adrian@cadifra.com>
parents:
12643
diff
changeset
|
28 > hg --cwd ../test2 push http://localhost:$HGPORT/ |
17455
2212af23c9de
test-push-http: include exit status of hg push
Yuya Nishihara <yuya@tcha.org>
parents:
17018
diff
changeset
|
29 > exitstatus=$? |
25474
8c14f87bd0ae
tests: drop DAEMON_PIDS from killdaemons calls
Matt Mackall <mpm@selenic.com>
parents:
25472
diff
changeset
|
30 > killdaemons.py |
12743
4c4aeaab2339
check-code: add 'no tab indent' check for unified tests
Adrian Buehlmann <adrian@cadifra.com>
parents:
12643
diff
changeset
|
31 > echo % serve errors |
4c4aeaab2339
check-code: add 'no tab indent' check for unified tests
Adrian Buehlmann <adrian@cadifra.com>
parents:
12643
diff
changeset
|
32 > cat errors.log |
17455
2212af23c9de
test-push-http: include exit status of hg push
Yuya Nishihara <yuya@tcha.org>
parents:
17018
diff
changeset
|
33 > return $exitstatus |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
34 > } |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
35 $ cd ../test |
2481
5c65b4e51610
add tests for push over http.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
diff
changeset
|
36 |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
37 expect ssl error |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
38 |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
39 $ req |
12643
d08bb64888bc
tests: reintroduce ":$HGPORT" in test output
Mads Kiilerich <mads@kiilerich.com>
parents:
12483
diff
changeset
|
40 pushing to http://localhost:$HGPORT/ |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
41 searching for changes |
17456
59a168019255
hgweb: respond 403 forbidden for ssl required error
Yuya Nishihara <yuya@tcha.org>
parents:
17455
diff
changeset
|
42 abort: HTTP Error 403: ssl required |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
43 % serve errors |
45839
ebee234d952a
errors: set detailed exit code to 100 for some remote errors
Martin von Zweigbergk <martinvonz@google.com>
parents:
42897
diff
changeset
|
44 [100] |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
45 |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
46 expect authorization error |
6167
f53b9a383476
tests: easier hg serve error diagnosis
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents:
5386
diff
changeset
|
47 |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
48 $ echo '[web]' > .hg/hgrc |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
49 $ echo 'push_ssl = false' >> .hg/hgrc |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
50 $ req |
12643
d08bb64888bc
tests: reintroduce ":$HGPORT" in test output
Mads Kiilerich <mads@kiilerich.com>
parents:
12483
diff
changeset
|
51 pushing to http://localhost:$HGPORT/ |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
52 searching for changes |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
53 abort: authorization failed |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
54 % serve errors |
17455
2212af23c9de
test-push-http: include exit status of hg push
Yuya Nishihara <yuya@tcha.org>
parents:
17018
diff
changeset
|
55 [255] |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
56 |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
57 expect authorization error: must have authorized user |
2481
5c65b4e51610
add tests for push over http.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
diff
changeset
|
58 |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
59 $ echo 'allow_push = unperson' >> .hg/hgrc |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
60 $ req |
12643
d08bb64888bc
tests: reintroduce ":$HGPORT" in test output
Mads Kiilerich <mads@kiilerich.com>
parents:
12483
diff
changeset
|
61 pushing to http://localhost:$HGPORT/ |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
62 searching for changes |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
63 abort: authorization failed |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
64 % serve errors |
17455
2212af23c9de
test-push-http: include exit status of hg push
Yuya Nishihara <yuya@tcha.org>
parents:
17018
diff
changeset
|
65 [255] |
2481
5c65b4e51610
add tests for push over http.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
diff
changeset
|
66 |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
67 expect success |
2481
5c65b4e51610
add tests for push over http.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
diff
changeset
|
68 |
34938
aa05b95949fe
tests: adjust hooks for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
34876
diff
changeset
|
69 $ cat > $TESTTMP/hook.sh <<'EOF' |
aa05b95949fe
tests: adjust hooks for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
34876
diff
changeset
|
70 > echo "phase-move: $HG_NODE: $HG_OLDPHASE -> $HG_PHASE" |
aa05b95949fe
tests: adjust hooks for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
34876
diff
changeset
|
71 > EOF |
aa05b95949fe
tests: adjust hooks for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
34876
diff
changeset
|
72 |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
73 #if bundle1 |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
74 $ cat >> .hg/hgrc <<EOF |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
75 > allow_push = * |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
76 > [hooks] |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
77 > changegroup = sh -c "printenv.py --line changegroup 0" |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
78 > pushkey = sh -c "printenv.py --line pushkey 0" |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
79 > txnclose-phase.test = sh $TESTTMP/hook.sh |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
80 > EOF |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
81 $ req "--debug --config extensions.blackbox=" |
37592
fb91757471b5
tests: glob away fqdn wherever we print it
Augie Fackler <augie@google.com>
parents:
37478
diff
changeset
|
82 listening at http://*:$HGPORT/ (bound to $LOCALIP:$HGPORT) (glob) (?) |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
83 pushing to http://localhost:$HGPORT/ |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
84 searching for changes |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
85 remote: redirecting incoming bundle to */hg-unbundle-* (glob) |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
86 remote: adding changesets |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
87 remote: add changeset ba677d0156c1 |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
88 remote: adding manifests |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
89 remote: adding file changes |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
90 remote: adding a revisions |
42897
d7304434390f
changegroup: move message about added changes to transaction summary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41896
diff
changeset
|
91 remote: updating the branch cache |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
92 remote: added 1 changesets with 1 changes to 1 files |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
93 remote: running hook txnclose-phase.test: sh $TESTTMP/hook.sh |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
94 remote: phase-move: cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b: draft -> public |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
95 remote: running hook txnclose-phase.test: sh $TESTTMP/hook.sh |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
96 remote: phase-move: ba677d0156c1196c1a699fa53f390dcfc3ce3872: -> public |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
97 remote: running hook changegroup: sh -c "printenv.py --line changegroup 0" |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
98 remote: changegroup hook: HG_HOOKNAME=changegroup |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
99 remote: HG_HOOKTYPE=changegroup |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
100 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
101 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
102 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
103 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
104 remote: HG_TXNNAME=serve |
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
105 remote: remote:http:$LOCALIP: (glob) |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
106 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
107 remote: |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
108 % serve errors |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
109 $ hg rollback |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
110 repository tip rolled back to revision 0 (undo serve) |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
111 $ req "--debug --config server.streamunbundle=True --config extensions.blackbox=" |
37592
fb91757471b5
tests: glob away fqdn wherever we print it
Augie Fackler <augie@google.com>
parents:
37478
diff
changeset
|
112 listening at http://*:$HGPORT/ (bound to $LOCALIP:$HGPORT) (glob) (?) |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
113 pushing to http://localhost:$HGPORT/ |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
114 searching for changes |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
115 remote: adding changesets |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
116 remote: add changeset ba677d0156c1 |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
117 remote: adding manifests |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
118 remote: adding file changes |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
119 remote: adding a revisions |
42897
d7304434390f
changegroup: move message about added changes to transaction summary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41896
diff
changeset
|
120 remote: updating the branch cache |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
121 remote: added 1 changesets with 1 changes to 1 files |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
122 remote: running hook txnclose-phase.test: sh $TESTTMP/hook.sh |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
123 remote: phase-move: cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b: draft -> public |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
124 remote: running hook txnclose-phase.test: sh $TESTTMP/hook.sh |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
125 remote: phase-move: ba677d0156c1196c1a699fa53f390dcfc3ce3872: -> public |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
126 remote: running hook changegroup: sh -c "printenv.py --line changegroup 0" |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
127 remote: changegroup hook: HG_HOOKNAME=changegroup |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
128 remote: HG_HOOKTYPE=changegroup |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
129 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
130 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
131 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
132 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
133 remote: HG_TXNNAME=serve |
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
134 remote: remote:http:$LOCALIP: (glob) |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
135 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
136 remote: |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
137 % serve errors |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
138 $ hg rollback |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
139 repository tip rolled back to revision 0 (undo serve) |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
140 #endif |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
141 |
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
142 #if bundle2 |
30234
34a5f6c66bc5
tests: invoke printenv.py via sh -c for test portability
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
27739
diff
changeset
|
143 $ cat >> .hg/hgrc <<EOF |
34a5f6c66bc5
tests: invoke printenv.py via sh -c for test portability
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
27739
diff
changeset
|
144 > allow_push = * |
34a5f6c66bc5
tests: invoke printenv.py via sh -c for test portability
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
27739
diff
changeset
|
145 > [hooks] |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
146 > changegroup = sh -c "printenv.py --line changegroup 0" |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
147 > pushkey = sh -c "printenv.py --line pushkey 0" |
34938
aa05b95949fe
tests: adjust hooks for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
34876
diff
changeset
|
148 > txnclose-phase.test = sh $TESTTMP/hook.sh |
30234
34a5f6c66bc5
tests: invoke printenv.py via sh -c for test portability
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
27739
diff
changeset
|
149 > EOF |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
150 $ req |
12643
d08bb64888bc
tests: reintroduce ":$HGPORT" in test output
Mads Kiilerich <mads@kiilerich.com>
parents:
12483
diff
changeset
|
151 pushing to http://localhost:$HGPORT/ |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
152 searching for changes |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
153 remote: adding changesets |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
154 remote: adding manifests |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
155 remote: adding file changes |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
156 remote: added 1 changesets with 1 changes to 1 files |
34876
eb1b964b354b
phases: pass phase names to hooks instead of internal values
Kevin Bullock <kbullock+mercurial@ringworld.org>
parents:
34836
diff
changeset
|
157 remote: phase-move: cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b: draft -> public |
eb1b964b354b
phases: pass phase names to hooks instead of internal values
Kevin Bullock <kbullock+mercurial@ringworld.org>
parents:
34836
diff
changeset
|
158 remote: phase-move: ba677d0156c1196c1a699fa53f390dcfc3ce3872: -> public |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
159 remote: changegroup hook: HG_BUNDLE2=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
160 remote: HG_HOOKNAME=changegroup |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
161 remote: HG_HOOKTYPE=changegroup |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
162 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
163 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
164 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
165 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
166 remote: HG_TXNNAME=serve |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
167 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
168 remote: |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
169 % serve errors |
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
170 $ hg rollback |
13446
1e497df514e2
rollback: clarifies the message about the reverted state (issue2628)
Gilles Moris <gilles.moris@free.fr>
parents:
13405
diff
changeset
|
171 repository tip rolled back to revision 0 (undo serve) |
37414
2d965bfeb8f6
wireproto: allow direct stream processing for unbundle
Joerg Sonnenberger <joerg@bec.de>
parents:
36751
diff
changeset
|
172 #endif |
12483
fecd4966f8d4
tests: unify test-push-http
Matt Mackall <mpm@selenic.com>
parents:
11469
diff
changeset
|
173 |
14093
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
174 expect success, server lacks the httpheader capability |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
175 |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
176 $ CAP=httpheader |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
177 $ . "$TESTDIR/notcapable" |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
178 $ req |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
179 pushing to http://localhost:$HGPORT/ |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
180 searching for changes |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
181 remote: adding changesets |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
182 remote: adding manifests |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
183 remote: adding file changes |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
184 remote: added 1 changesets with 1 changes to 1 files |
34876
eb1b964b354b
phases: pass phase names to hooks instead of internal values
Kevin Bullock <kbullock+mercurial@ringworld.org>
parents:
34836
diff
changeset
|
185 remote: phase-move: cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b: draft -> public |
eb1b964b354b
phases: pass phase names to hooks instead of internal values
Kevin Bullock <kbullock+mercurial@ringworld.org>
parents:
34836
diff
changeset
|
186 remote: phase-move: ba677d0156c1196c1a699fa53f390dcfc3ce3872: -> public |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
187 remote: changegroup hook: HG_HOOKNAME=changegroup (no-bundle2 !) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
188 remote: changegroup hook: HG_BUNDLE2=1 (bundle2 !) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
189 remote: HG_HOOKNAME=changegroup (bundle2 !) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
190 remote: HG_HOOKTYPE=changegroup |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
191 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
192 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
193 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
194 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
195 remote: HG_TXNNAME=serve |
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
196 remote: remote:http:$LOCALIP: (glob) (no-bundle2 !) |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
197 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
198 remote: |
14093
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
199 % serve errors |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
200 $ hg rollback |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
201 repository tip rolled back to revision 0 (undo serve) |
ce99d887585f
httprepo: long arguments support (issue2126)
Steven Brown <StevenGBrown@gmail.com>
parents:
14011
diff
changeset
|
202 |
13946
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
203 expect success, server lacks the unbundlehash capability |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
204 |
14011
b69471bdb678
tests: add script to disable a selected wire protocol capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13946
diff
changeset
|
205 $ CAP=unbundlehash |
b69471bdb678
tests: add script to disable a selected wire protocol capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13946
diff
changeset
|
206 $ . "$TESTDIR/notcapable" |
13946
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
207 $ req |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
208 pushing to http://localhost:$HGPORT/ |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
209 searching for changes |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
210 remote: adding changesets |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
211 remote: adding manifests |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
212 remote: adding file changes |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
213 remote: added 1 changesets with 1 changes to 1 files |
34876
eb1b964b354b
phases: pass phase names to hooks instead of internal values
Kevin Bullock <kbullock+mercurial@ringworld.org>
parents:
34836
diff
changeset
|
214 remote: phase-move: cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b: draft -> public |
eb1b964b354b
phases: pass phase names to hooks instead of internal values
Kevin Bullock <kbullock+mercurial@ringworld.org>
parents:
34836
diff
changeset
|
215 remote: phase-move: ba677d0156c1196c1a699fa53f390dcfc3ce3872: -> public |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
216 remote: changegroup hook: HG_HOOKNAME=changegroup (no-bundle2 !) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
217 remote: changegroup hook: HG_BUNDLE2=1 (bundle2 !) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
218 remote: HG_HOOKNAME=changegroup (bundle2 !) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
219 remote: HG_HOOKTYPE=changegroup |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
220 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
221 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
222 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
223 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
224 remote: HG_TXNNAME=serve |
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
225 remote: remote:http:$LOCALIP: (glob) (no-bundle2 !) |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
226 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
227 remote: |
13946
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
228 % serve errors |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
229 $ hg rollback |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
230 repository tip rolled back to revision 0 (undo serve) |
3c2f9f611ef6
tests: new test cases for the unbundlehash capability
Steven Brown <StevenGBrown@gmail.com>
parents:
13449
diff
changeset
|
231 |
36241
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
232 expect success, pre-d1b16a746db6 server supports the unbundle capability, but |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
233 has no parameter |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
234 |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
235 $ cat <<EOF > notcapable-unbundleparam.py |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
236 > from mercurial import extensions, httppeer |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
237 > def capable(orig, self, name): |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
238 > if name == 'unbundle': |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
239 > return True |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
240 > return orig(self, name) |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
241 > def uisetup(ui): |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
242 > extensions.wrapfunction(httppeer.httppeer, 'capable', capable) |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
243 > EOF |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
244 $ cp $HGRCPATH $HGRCPATH.orig |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
245 $ cat <<EOF >> $HGRCPATH |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
246 > [extensions] |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
247 > notcapable-unbundleparam = `pwd`/notcapable-unbundleparam.py |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
248 > EOF |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
249 $ req |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
250 pushing to http://localhost:$HGPORT/ |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
251 searching for changes |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
252 remote: adding changesets |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
253 remote: adding manifests |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
254 remote: adding file changes |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
255 remote: added 1 changesets with 1 changes to 1 files |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
256 remote: phase-move: cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b: draft -> public |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
257 remote: phase-move: ba677d0156c1196c1a699fa53f390dcfc3ce3872: -> public |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
258 remote: changegroup hook: * (glob) |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
259 remote: HG_HOOKNAME=changegroup (bundle2 !) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
260 remote: HG_HOOKTYPE=changegroup |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
261 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
262 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
263 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
264 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
265 remote: HG_TXNNAME=serve |
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
266 remote: remote:http:$LOCALIP: (glob) (no-bundle2 !) |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
267 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
268 remote: |
36241
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
269 % serve errors |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
270 $ hg rollback |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
271 repository tip rolled back to revision 0 (undo serve) |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
272 $ mv $HGRCPATH.orig $HGRCPATH |
fefd57bd9573
tests: port value-less unbundle capability test to test-push-http.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34938
diff
changeset
|
273 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
274 Test pushing to a publishing repository with a failing prepushkey hook |
17793
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
275 |
17842
a029dac38942
test-push-http: fix failing test on Windows
Adrian Buehlmann <adrian@cadifra.com>
parents:
17793
diff
changeset
|
276 $ cat > .hg/hgrc <<EOF |
a029dac38942
test-push-http: fix failing test on Windows
Adrian Buehlmann <adrian@cadifra.com>
parents:
17793
diff
changeset
|
277 > [web] |
a029dac38942
test-push-http: fix failing test on Windows
Adrian Buehlmann <adrian@cadifra.com>
parents:
17793
diff
changeset
|
278 > push_ssl = false |
a029dac38942
test-push-http: fix failing test on Windows
Adrian Buehlmann <adrian@cadifra.com>
parents:
17793
diff
changeset
|
279 > allow_push = * |
a029dac38942
test-push-http: fix failing test on Windows
Adrian Buehlmann <adrian@cadifra.com>
parents:
17793
diff
changeset
|
280 > [hooks] |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
281 > prepushkey = sh -c "printenv.py --line prepushkey 1" |
34836
537de0b14030
phase: use a binary phase part to push through bundle2 (BC)
Boris Feld <boris.feld@octobus.net>
parents:
34710
diff
changeset
|
282 > [devel] |
537de0b14030
phase: use a binary phase part to push through bundle2 (BC)
Boris Feld <boris.feld@octobus.net>
parents:
34710
diff
changeset
|
283 > legacy.exchange=phases |
17842
a029dac38942
test-push-http: fix failing test on Windows
Adrian Buehlmann <adrian@cadifra.com>
parents:
17793
diff
changeset
|
284 > EOF |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
285 |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
286 #if bundle1 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
287 Bundle1 works because a) phases are updated as part of changegroup application |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
288 and b) client checks phases after the "unbundle" command. Since it sees no |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
289 phase changes are necessary, it doesn't send the "pushkey" command and the |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
290 prepushkey hook never has to fire. |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
291 |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
292 $ req |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
293 pushing to http://localhost:$HGPORT/ |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
294 searching for changes |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
295 remote: adding changesets |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
296 remote: adding manifests |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
297 remote: adding file changes |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
298 remote: added 1 changesets with 1 changes to 1 files |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
299 % serve errors |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
300 |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
301 #endif |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
302 |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
303 #if bundle2 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
304 Bundle2 sends a "pushkey" bundle2 part. This runs as part of the transaction |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
305 and fails the entire push. |
17793
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
306 $ req |
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
307 pushing to http://localhost:$HGPORT/ |
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
308 searching for changes |
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
309 remote: adding changesets |
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
310 remote: adding manifests |
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
311 remote: adding file changes |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
312 remote: prepushkey hook: HG_BUNDLE2=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
313 remote: HG_HOOKNAME=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
314 remote: HG_HOOKTYPE=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
315 remote: HG_KEY=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
316 remote: HG_NAMESPACE=phases |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
317 remote: HG_NEW=0 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
318 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
319 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
320 remote: HG_OLD=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
321 remote: HG_PENDING=$TESTTMP/test |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
322 remote: HG_PHASES_MOVED=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
323 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
324 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
325 remote: HG_TXNNAME=serve |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
326 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
327 remote: |
25390
14c6b4c6e3f9
test: use bundle2 in test-push-http
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
24740
diff
changeset
|
328 remote: pushkey-abort: prepushkey hook exited with status 1 |
25502
bd41c19383db
phases: abort the whole push if phases fail to update (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
25478
diff
changeset
|
329 remote: transaction abort! |
bd41c19383db
phases: abort the whole push if phases fail to update (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
25478
diff
changeset
|
330 remote: rollback completed |
bd41c19383db
phases: abort the whole push if phases fail to update (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
25478
diff
changeset
|
331 abort: updating ba677d0156c1 to public failed |
17793
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
332 % serve errors |
25502
bd41c19383db
phases: abort the whole push if phases fail to update (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
25478
diff
changeset
|
333 [255] |
17793
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
334 |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
335 #endif |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
336 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
337 Now remove the failing prepushkey hook. |
17793
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
338 |
30234
34a5f6c66bc5
tests: invoke printenv.py via sh -c for test portability
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
27739
diff
changeset
|
339 $ cat >> .hg/hgrc <<EOF |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
340 > [hooks] |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
341 > prepushkey = sh -c "printenv.py --line prepushkey 0" |
30234
34a5f6c66bc5
tests: invoke printenv.py via sh -c for test portability
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
27739
diff
changeset
|
342 > EOF |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
343 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
344 We don't need to test bundle1 because it succeeded above. |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
345 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
346 #if bundle2 |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
347 $ req |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
348 pushing to http://localhost:$HGPORT/ |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
349 searching for changes |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
350 remote: adding changesets |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
351 remote: adding manifests |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
352 remote: adding file changes |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
353 remote: prepushkey hook: HG_BUNDLE2=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
354 remote: HG_HOOKNAME=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
355 remote: HG_HOOKTYPE=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
356 remote: HG_KEY=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
357 remote: HG_NAMESPACE=phases |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
358 remote: HG_NEW=0 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
359 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
360 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
361 remote: HG_OLD=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
362 remote: HG_PENDING=$TESTTMP/test |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
363 remote: HG_PHASES_MOVED=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
364 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
365 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
366 remote: HG_TXNNAME=serve |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
367 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
368 remote: |
42897
d7304434390f
changegroup: move message about added changes to transaction summary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41896
diff
changeset
|
369 remote: added 1 changesets with 1 changes to 1 files |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
370 % serve errors |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
371 #endif |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
372 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
373 $ hg --config extensions.strip= strip -r 1: |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
374 saved backup bundle to $TESTTMP/test/.hg/strip-backup/ba677d0156c1-eea704d7-backup.hg |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
375 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
376 Now do a variant of the above, except on a non-publishing repository |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
377 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
378 $ cat >> .hg/hgrc <<EOF |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
379 > [phases] |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
380 > publish = false |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
381 > [hooks] |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
382 > prepushkey = sh -c "printenv.py --line prepushkey 1" |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
383 > EOF |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
384 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
385 #if bundle1 |
17793
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
386 $ req |
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
387 pushing to http://localhost:$HGPORT/ |
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
388 searching for changes |
25502
bd41c19383db
phases: abort the whole push if phases fail to update (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
25478
diff
changeset
|
389 remote: adding changesets |
bd41c19383db
phases: abort the whole push if phases fail to update (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
25478
diff
changeset
|
390 remote: adding manifests |
bd41c19383db
phases: abort the whole push if phases fail to update (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
25478
diff
changeset
|
391 remote: adding file changes |
bd41c19383db
phases: abort the whole push if phases fail to update (BC)
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
25478
diff
changeset
|
392 remote: added 1 changesets with 1 changes to 1 files |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
393 remote: prepushkey hook: HG_HOOKNAME=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
394 remote: HG_HOOKTYPE=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
395 remote: HG_KEY=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
396 remote: HG_NAMESPACE=phases |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
397 remote: HG_NEW=0 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
398 remote: HG_OLD=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
399 remote: |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
400 remote: pushkey-abort: prepushkey hook exited with status 1 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
401 updating ba677d0156c1 to public failed! |
17793
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
402 % serve errors |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
403 #endif |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
404 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
405 #if bundle2 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
406 $ req |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
407 pushing to http://localhost:$HGPORT/ |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
408 searching for changes |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
409 remote: adding changesets |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
410 remote: adding manifests |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
411 remote: adding file changes |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
412 remote: prepushkey hook: HG_BUNDLE2=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
413 remote: HG_HOOKNAME=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
414 remote: HG_HOOKTYPE=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
415 remote: HG_KEY=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
416 remote: HG_NAMESPACE=phases |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
417 remote: HG_NEW=0 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
418 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
419 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
420 remote: HG_OLD=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
421 remote: HG_PENDING=$TESTTMP/test |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
422 remote: HG_PHASES_MOVED=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
423 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
424 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
425 remote: HG_TXNNAME=serve |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
426 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
427 remote: |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
428 remote: pushkey-abort: prepushkey hook exited with status 1 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
429 remote: transaction abort! |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
430 remote: rollback completed |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
431 abort: updating ba677d0156c1 to public failed |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
432 % serve errors |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
433 [255] |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
434 #endif |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
435 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
436 Make phases updates work |
17793
8474be4412ca
wireproto: fix pushkey hook failure and output on remote http repo
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
17565
diff
changeset
|
437 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
438 $ cat >> .hg/hgrc <<EOF |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
439 > [hooks] |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
440 > prepushkey = sh -c "printenv.py --line prepushkey 0" |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
441 > EOF |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
442 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
443 #if bundle1 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
444 $ req |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
445 pushing to http://localhost:$HGPORT/ |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
446 searching for changes |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
447 no changes found |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
448 remote: prepushkey hook: HG_HOOKNAME=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
449 remote: HG_HOOKTYPE=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
450 remote: HG_KEY=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
451 remote: HG_NAMESPACE=phases |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
452 remote: HG_NEW=0 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
453 remote: HG_OLD=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
454 remote: |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
455 % serve errors |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
456 [1] |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
457 #endif |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
458 |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
459 #if bundle2 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
460 $ req |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
461 pushing to http://localhost:$HGPORT/ |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
462 searching for changes |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
463 remote: adding changesets |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
464 remote: adding manifests |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
465 remote: adding file changes |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
466 remote: prepushkey hook: HG_BUNDLE2=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
467 remote: HG_HOOKNAME=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
468 remote: HG_HOOKTYPE=prepushkey |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
469 remote: HG_KEY=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
470 remote: HG_NAMESPACE=phases |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
471 remote: HG_NEW=0 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
472 remote: HG_NODE=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
473 remote: HG_NODE_LAST=ba677d0156c1196c1a699fa53f390dcfc3ce3872 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
474 remote: HG_OLD=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
475 remote: HG_PENDING=$TESTTMP/test |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
476 remote: HG_PHASES_MOVED=1 |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
477 remote: HG_SOURCE=serve |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
478 remote: HG_TXNID=TXN:$ID$ |
41896
94faa2e84094
transaction: include txnname in the hookargs dictionary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41642
diff
changeset
|
479 remote: HG_TXNNAME=serve |
41642
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
480 remote: HG_URL=remote:http:$LOCALIP: (glob) |
7839249e7834
test: use `printenv.py --line` in `test-push-http.t`
Boris Feld <boris.feld@octobus.net>
parents:
38722
diff
changeset
|
481 remote: |
42897
d7304434390f
changegroup: move message about added changes to transaction summary
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41896
diff
changeset
|
482 remote: added 1 changesets with 1 changes to 1 files |
36243
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
483 % serve errors |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
484 #endif |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
485 |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
486 $ hg --config extensions.strip= strip -r 1: |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
487 saved backup bundle to $TESTTMP/test/.hg/strip-backup/ba677d0156c1-eea704d7-backup.hg |
c19e66dacaa1
tests: expand test coverage for updating phases
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36242
diff
changeset
|
488 |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
489 #if bundle2 |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
490 |
33700
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
491 $ cat > .hg/hgrc <<EOF |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
492 > [web] |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
493 > push_ssl = false |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
494 > allow_push = * |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
495 > [experimental] |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
496 > httppostargs=true |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
497 > EOF |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
498 $ req |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
499 pushing to http://localhost:$HGPORT/ |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
500 searching for changes |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
501 remote: adding changesets |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
502 remote: adding manifests |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
503 remote: adding file changes |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
504 remote: added 1 changesets with 1 changes to 1 files |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
505 % serve errors |
970967e0a917
http: add a test of actually pushing with httppostargs
Augie Fackler <augie@google.com>
parents:
31815
diff
changeset
|
506 |
36242
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
507 #endif |
477280637646
tests: consolidate test-push-http.t and test-push-http-bundle1.t
Gregory Szorc <gregory.szorc@gmail.com>
parents:
36241
diff
changeset
|
508 |
16913
f2719b387380
tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents:
15933
diff
changeset
|
509 $ cd .. |
37818
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
510 |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
511 Pushing via hgwebdir works |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
512 |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
513 $ hg init hgwebdir |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
514 $ cd hgwebdir |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
515 $ echo 0 > a |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
516 $ hg -q commit -A -m initial |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
517 $ cd .. |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
518 |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
519 $ cat > web.conf << EOF |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
520 > [paths] |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
521 > / = * |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
522 > [web] |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
523 > push_ssl = false |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
524 > allow_push = * |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
525 > EOF |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
526 |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
527 $ hg serve --web-conf web.conf -p $HGPORT -d --pid-file hg.pid |
37824
2968ad548583
test-push-http: do not clear pid file
Yuya Nishihara <yuya@tcha.org>
parents:
37818
diff
changeset
|
528 $ cat hg.pid >> $DAEMON_PIDS |
37818
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
529 |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
530 $ hg clone http://localhost:$HGPORT/hgwebdir hgwebdir-local |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
531 requesting all changes |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
532 adding changesets |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
533 adding manifests |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
534 adding file changes |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
535 added 1 changesets with 1 changes to 1 files |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
536 new changesets 98a3f8f02ba7 |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
537 updating to branch default |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
538 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
539 $ cd hgwebdir-local |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
540 $ echo commit > a |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
541 $ hg commit -m 'local commit' |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
542 |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
543 $ hg push |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
544 pushing to http://localhost:$HGPORT/hgwebdir |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
545 searching for changes |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
546 remote: adding changesets |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
547 remote: adding manifests |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
548 remote: adding file changes |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
549 remote: added 1 changesets with 1 changes to 1 files |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
550 |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
551 $ killdaemons.py |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
552 |
877185de62cf
hgweb: reuse body file object when hgwebdir calls hgweb (issue5851)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37592
diff
changeset
|
553 $ cd .. |