On Nov 9, 2007, at 9:43 AM, Jim Fulton wrote:

Yawn. IMO, the test command in setuptools is a waste of time, because it doesn't work with anything else.

It runs all the tests, even the doctests, if thats what you mean. See the "additional_tests" hair in the test modules.

My point is that the meta data you added to the setup.py only works with setup.py. It isn't accessible to any other test runners. I shouldn't have yawned. It is significant that the tests work. :) I just don't find this way of running the tests to be useful. The first time I work on this package, I'll add a buildout.cfg so I can use the Zope test runner. At that point, I'll have to deal with these extra requirements in another way (which is no big deal).

What if we caused setup.py to read a buildout.cfg for the tests_require package names and we passed these in as tests_require= names? Would that make it all better?

zope.interface is a real requirement. It is already in test_requires.

Over time, we need to clean up the transaction tests so they don't use ZODB.

Yeah, given that we're name this thing "transaction", it's an actually an immediate requirement.

If you are going to spend the time, then, uh, sure. ;) Seriously, while I would love to see this cleaned up, I don't think I would consider this super urgent. I guess that depends on competing priorities.

I just deleted the sections of the test_transaction doctests that depended on ZODB. They were actually not really testing transactions, they were testing persistent object behavior. I'll try to put them back in a form within ZODB proper, as the test really are testing ZODB functionality, not transaction functionality.

There's only one test that uses anything that can't be mocked up in the transaction package (it uses an actual MappingStorage and a DB) itself. It also happens to be the one that fails right now; I haven't tried to understand it yet.

Gah. BTW, if you haven't already, you should check for transaction tests lurking in the other ZODB packages.

Good idea.

In the meantime, I've gotten rid of 'zope.transaction' and I've created a new top-level 'transaction' package at http://svn.zope.org/transaction/ . All its tests pass. It depends only on 'zope.interface', and requires 'zope.testing' for running the tests.

- C

For more information about ZODB, see the ZODB Wiki:

ZODB-Dev mailing list  -  ZODB-Dev@zope.org

Reply via email to