location of non-test test code

Robert Collins robertc at robertcollins.net
Sat Jul 15 15:20:58 BST 2006


So we have quite some non-test test code:
 * test protocol servers
 * lock test helpers
 * most of bzrlib/tests/__init__.py

I'd like to make sure that all of bzrlib/tests/ is either test code, or
the actual code required to load the test suite, but not support code. 

The reason for this is that its IMO hard to know where to look for
support code if its sometimes near the relevant code, and sometimes in
bzrlib/tests.

Separately, but related, I've long desired to split our tests out across
the bzrlib namespace, putting them under the thing they test - i.e.
bzrlib.transport.tests for transport generic tests,
bzrlib.transport.sftp.tests for sftp specific tests, etc.

So, heres a two part proposal.

Part 1:
 Lets move all the non-test test code currently in bzrlib.tests to
bzrlib.selftest. If there is a clear home for it that is outside
bzrlib.selftest - i.e. if its os lock specific, then I would encourage
us to put it in lock.py.

Part 2:
 Lets split out the test suite for better locality of reference.

I'm much more interested in Part 1 than Part 2, so if Part 2 is
problematic, just ignore it ;).

Rob
-- 
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 191 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060716/321b2ce0/attachment.pgp 


More information about the bazaar mailing list