# HG changeset patch # User Pierre-Yves David # Date 1445336709 -7200 # Node ID 0856f1bfbe1e4ca3dd8930cbbba0ce4eb578b035 # Parent e36118815a39516504b8abc58fd43bcc3fb64a32 test: spread capabilities replies in 'test-hgweb-commands' Any changes to the capabilities string was very hard to review. So we introduce two tests. A small one that validates the format and a second one to validate the content, where each capability is on its own line to make changes simpler to review. diff -r e36118815a39 -r 0856f1bfbe1e tests/test-hgweb-commands.t --- a/tests/test-hgweb-commands.t Sat Nov 07 16:11:49 2015 -0800 +++ b/tests/test-hgweb-commands.t Tue Oct 20 12:25:09 2015 +0200 @@ -2098,10 +2098,34 @@ capabilities - $ get-with-headers.py 127.0.0.1:$HGPORT '?cmd=capabilities'; echo +(plain version to check the format) + + $ get-with-headers.py 127.0.0.1:$HGPORT '?cmd=capabilities' | dd ibs=75 count=1 2> /dev/null; echo 200 Script output follows - lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch stream-preferred stream bundle2=HG20%0Achangegroup%3D01%2C02%0Adigests%3Dmd5%2Csha1*%0Alistkeys%0Apushkey%0Aremote-changegroup%3Dhttp%2Chttps unbundle=HG10GZ,HG10BZ,HG10UN httpheader=1024 (glob) + lookup changegroupsubset branchmap pushkey known + +(spread version to check the content) + + $ get-with-headers.py 127.0.0.1:$HGPORT '?cmd=capabilities' | tr ' ' '\n'; echo + 200 + Script + output + follows + + lookup + changegroupsubset + branchmap + pushkey + known + getbundle + unbundlehash + batch + stream-preferred + stream + bundle2=HG20%0Achangegroup%3D01%2C02%0Adigests%3Dmd5%2Csha1%2Csha512%0Aerror%3Dabort%2Cunsupportedcontent%2Cpushraced%2Cpushkey%0Ahgtagsfnodes%0Alistkeys%0Apushkey%0Aremote-changegroup%3Dhttp%2Chttps + unbundle=HG10GZ,HG10BZ,HG10UN + httpheader=1024 heads