[MERGE] Add Remote-v2 variant to branch/repository/bzrdir implementations tests.

Andrew Bennetts andrew at canonical.com
Wed Jun 18 08:14:14 BST 2008


This patch adds another scenario to the parameterised tests that already take
Remote* objects to test HPSS protocol v2 (and <= 1.2 HPSS verbs).  This
exercises both the v2 client and server code, and also any fallback logic in the
Remote* client objects for coping with 1.2 servers (and thus exercising verbs
that might only get used by those clients).

So instead of e.g. RemoteBranchFormat tests, there are now
RemoteBranchFormat-default and RemoteBranchFormat-v2 tests.  It relies on a new
SmartTCPServer_for_testing_v2_only class, which uses a simple variant of
RemoteTCPTransport called RemoteTCPTransportV2Only.  That transport simply tells
the client medium to assume that protocol 2 and pre-1.6 verbs.

A possibly helpful side-effect is that there's now a bzr-v2:// protocol
registered.  This *might* be helpful for debugging outside the test suite,
although perhaps it shouldn't be registered unless tests are running to
discourage casual use.  It's no worse than having memory:/// registered I guess.

This patch has been helpful in testing experimental new work on
bzrlib/remote.py.

-Andrew.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: old-hpss-remote-object-tests.patch
Type: text/x-diff
Size: 12082 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20080618/c91cc50b/attachment-0001.bin 


More information about the bazaar mailing list